[m-users.] Mercury Crash Course

Julien Fischer jfischer at opturion.com
Tue Aug 6 11:41:50 AEST 2019


On Mon, 5 Aug 2019, Philip White wrote:

> One thing I'm wondering follows from 3.9. Functions are just a specific
> kind of predicate, but with more convenient syntax. If a predicate
> satisfies the conditions of a function, is there ever downside to making
> it a function?

Two spring to mind:

* Functions are prone to type ambiguities.
* They are less amenable to state variable notation.

> Unrelated to the crash course, but related to learning material: I
> imagine this mailing list has a lot of questions that have been answered
> (from my short experience in the past couple days, the answers are high
> quality as well). The website says that the archives are searchable, 
>
> - but I don't know how to without finding some other websites that index
> - mailing lists.

There's a search bar for the mailing lists about half way down the
following page: <http://www.mercurylang.org/contact.html>.
(That just forwards all the work to Google, but does safe a bit of
typing.)

> Perhaps the crash course could have a section on how to find
> documentation; that is always a trouble for me it seems. Ways I've been
> doing it are:
>
> 1. Search through the compiler source code
> 2. Read the language reference manual
> 3. Read the Ralph Becket tutorial (not very complete).

As Ralph has not been involved with Mercury for many years now, I think
the chances of it ever being more complete are quite slim.

> 4. Hope google has an answer for me (never works).

We have the beginnings of another tutorial sitting on the wiki
on github: <https://github.com/Mercury-Language/mercury/wiki/Tutorial>.

Julien.


More information about the users mailing list