[mercury-users] Debugging Mercury Programs
Ralph Becket
rwab1 at cam.sri.com
Wed Oct 22 03:31:11 AEST 1997
> :- pred trc_msg(string).
> :- mode trc_msg(in) is semidet.
>
> :- pragma c_code(
> trc_msg(Msg::in),
> may_call_mercury,
> "{
> printf("\ntrc_msg: %s\n", Msg);
> }").
Just to clarify: the semidet declaration is there to prevent the
compiler from optimising away calls to trc_msg/1.
--
Ralph Becket | rwab1 at cam.sri.com | http://www.cam.sri.com/people/becket.html
More information about the users
mailing list