users-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: question and bug report for gprolog 1.2.14


From: Erick Alphonse
Subject: Re: question and bug report for gprolog 1.2.14
Date: Fri, 13 Sep 2002 21:47:07 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.1) Gecko/20020826

Daniel Diaz wrote:
Erick Alphonse wrote:


2) I get a segmentation violation with term_ref:
GNU Prolog 1.2.14
By Daniel Diaz
Copyright (C) 1999-2002 Daniel Diaz
| ?- term_ref(X,12).

Fatal Error: Segmentation Violation


This is due to bad use of term_ref/2 (see the doc). If a Ref is
specified (e.g. 12) you should be sure that it corresponds to a term
(i.e. it is a valid Ref). It is not the case here. The only way to be
ensure this is to reuse a Ref given by term_ref.

Thank you Daniel. I understood it this way, but thought it was a bug because the doc doesn't say anything about that and goes :

term_ref(Term, Ref) succeeds if the internal reference of Term is Ref.

I think the doc should be updated then, but not by adding something like "and segfaults otherwise" ;-).

Cheers,
Erick.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]