Re: [] \= '[]' (was Re: Ann: SWI-Prolog 7.1.0)
"Richard A. O'Keefe" <[email protected]>
| Newsgroups | gmane.comp.ai.prolog.swi |
|---|---|
| Message-ID | <[email protected]> |
On 28/11/2013, at 4:09 AM, Jan Wielemaker wrote: > > Not really. There have been attributed variables and strings for a long > time. They don't break the traditional hierarchy at all. Attributed variables satisfy var/1. There is more to know about them, but usually you don't care to know it. strings are just constants; Prolog systems have long had a range of things that are atomic/1 but do not satisfy atom/1 or number/1. > At some point, it is likely that there will be rational numbers as > a real type rather than a compound rdiv(N,D). That will actually *improve* the fit to the traditional hierarchy. > > > What I'm after is more runtime type information, Well, we had better introduce objects and classes then. > I would have been happy to > introduce a real type `list'. It would have made Prolog a more complicated language. Many Prolog systems had a special *run-time* representation for dotted pairs without this needing to be surfaced in the *semantics* of the language. You know, it's the first thing I look for in Prolog source code. Documentation of the intended data structures. Too often I don't find it.