When I am using SWI prolog program and run below code the result differs from GNU console as show:
atom([]).
false in SWI prolog while
atom([]).
is true in GNU console prolog.
2
votes
1 Answers
1
votes
SWI-Prolog 7.x and later versions made the empty list its own type, distinct from atom, a deviation from the ISO Prolog Core standard that GNU Prolog follows more closely, including in this case.
P.S. If you want to access a Prolog system (official and de facto) standards conformance, the Logtalk distribution includes a Prolog compliance suite (with ~1700 tests) that you can run with all its supported Prolog systems, which include both SWI-Prolog and GNU Prolog.