[mercury-users] try_io on x86-64

Michael Day mikeday at yeslogic.com
Fri Oct 9 09:52:19 AEDT 2009

Hi Julien,

> Mercury is primarily developed on Linux x86-64 systems these days; we
> haven't noticed any problems with try_io.

I can reproduce the bug with the program below and rotd-2008-01-30, but 
only when building with some optimisations enabled:

$ mmc --make try -O3 --intermodule-optimisation
Mercury/os/try.o:(.rodata+0x310): undefined reference to `<predicate 
'exception.wrap_success_or_failure'/2 mode 0>'
collect2: ld returned 1 exit status

:- module try.

:- interface.

:- import_module io.

:- pred main(io, io).
:- mode main(di, uo) is cc_multi.

:- implementation.

:- import_module int, exception.

main(!IO) :-
     try_io(test, Res, !IO),
     write(Res, !IO), nl(!IO).

:- pred test(int, io, io).
:- mode test(out, di, uo) is det.

test(17, !IO).

Can you see if this error still manifests in the latest version?



Print XML with Prince!
mercury-users mailing list
Post messages to:       mercury-users at csse.unimelb.edu.au
Administrative Queries: owner-mercury-users at csse.unimelb.edu.au
Subscriptions:          mercury-users-request at csse.unimelb.edu.au

More information about the users mailing list