Created
November 8, 2017 01:27
-
-
Save zeldangit/9448809d80f7613d74189feb9f5529ac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:- module test. | |
:- interface. | |
:- import_module io. | |
:- pred main(io::di, io::uo) is det. | |
:- implementation. | |
main(!IO) :- | |
io.write_string("Hello, world!\n", !IO). | |
:- import_module list. | |
:- func length(list(T)) = int. | |
length([]) = 0. | |
length([_ | Xs]) = 1 + length(Xs). | |
%$ mmc --make test | |
%Making Mercury/int3s/test.int3 | |
%Making Mercury/ints/test.int | |
%Making Mercury/cs/test.c | |
%test.m:012: In clause for function `length'/1: | |
%test.m:012: in function result term of clause head: | |
%test.m:012: error: undefined symbol `+/2'. | |
%** Error making `Mercury/cs/test.c'. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment