[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Segmentation fault with Gnu Prolog compiled under Cygwin
From: |
Pierre-François Bonnefoi |
Subject: |
Segmentation fault with Gnu Prolog compiled under Cygwin |
Date: |
Tue, 3 Jun 2003 11:37:14 +0200 |
Hello,
I've a problem with the following prolog code :
create_object(Node) :-
Attributs = [X, Y, Z, Width, Heigth, Depth],
fd_domain(Attributs, 0, 100),
atom_concat(Node, '_X', Id_X),
g_link(Id_X, X),
atom_concat(Node, '_Y', Id_Y),
g_link(Id_Y, Y).
propertie(Element) :-
atom_concat(Element, '_X', Id_X),
g_read(Id_X, X),
atom_concat(Element, '_Y', Id_Y),
g_read(Id_Y, Y),
X #> Y.
display(Element) :-
atom_concat(Element, '_X', Id_X),
g_read(Id_X, X),
atom_concat(Element, '_Y', Id_Y),
g_read(Id_Y, Y),
write(Id_X),
write(X),nl, write(Id_Y), write(Y).
And finally, I enter the following clause :
create_object(house), propertie(house), display(house).
I obtain a segmentation fault under Cygwin (Win XP) and that works under
Linux/BSD.
The purpose of this work is to make easy the access to variables (like
records) through global variables and with arguments passing.
The final work is to define a new operator and a DCG to simplify the
syntactic use of this form of records.
Pierre-François Bonnefoi.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Segmentation fault with Gnu Prolog compiled under Cygwin,
Pierre-François Bonnefoi <=