[mercury-users] Printing reference's values
Maria Garcia de la Banda
mbanda at mail.csse.monash.edu.au
Thu Dec 5 16:53:53 AEDT 2002
>> It's a good thing you asked, since I happen to know exactly what the problem is.
>> Currently there is a conflict between the `--reserve-tag' option, which you
>> are using for the HAL implementation, and the implementation of references in
>> extras/reference.
That would explain why I cannot get a small "all Mercury" program
displaying the bug.
>> The pragma c_code used in extras/references is declared to
>> return a `ref', but actually just returns a c_pointer.
>> When io__write is called on one of these values, it tries to
>> look at the (non-existant) tag, and then tries to dereference
>> something which isn't there or otherwise gets confused.
But I cannot see how that explains why:
(a) the first write works while the second bombs out
(b) the second write bobms after writting part of the tree (after a bit
of debugging I found out it bombs during the 11th call to
deconstruct:deconstruct).
Cheers,
Maria
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list