[m-users.] [Beginner] Using a functions from 'libs'

Julien Fischer jfischer at opturion.com
Sun Oct 16 18:56:14 AEDT 2022



On Sun, 16 Oct 2022, Razetime wrote:

> using the name md5 like follows:
> :- module a05.
>
> :- interface.
> :- import_module io.
> :- pred main(io::uo,io::di) is det.
>
> :- implementation.
> :- import_module list.
> :- import_module md5.
>
> main(!IO):-
>  S0=md5sum("abc3231929"),
>  print_line(S0,!IO)
>  .
>
> gives me this error:
> $ mmcb a05.m
> ~
>                                                 │mercury_compile:
> cannot find `Mercury/ints/md5.int' in directories .,
> ~
>> /usr/lib/mercury/ints

Using mmc directly like that is only for building single module
programs.  To build a program consisting of multiple modules, use
the --make option, e.g.

     $ mmc --make a05

(See the "Using the Mercury compile" section of the Mercury users's
guide for details.)

Julien.


More information about the users mailing list