home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.prolog
- Path: sparky!uunet!charon.amdahl.com!pacbell.com!mips!sdd.hp.com!caen!umeecs!umn.edu!lynx!nmsu.edu!opus!ted
- From: ted@nmsu.edu (Ted Dunning)
- Subject: Re: SICStus Prolog singleton warnings slow down while consulting a file
- In-Reply-To: ken@aiai.ed.ac.uk's message of 18 Aug 92 17:16:03 GMT
- Message-ID: <TED.92Aug19112723@aeolia.nmsu.edu>
- Followup-To: comp.lang.prolog
- Sender: usenet@nmsu.edu
- Reply-To: ted@nmsu.edu
- Organization: Computing Research Lab
- References: <1992Aug17.172126.19111@watson.ibm.com> <5100@sersun1.essex.ac.uk>
- <7240@skye.ed.ac.uk>
- Date: Wed, 19 Aug 1992 18:27:23 GMT
- Lines: 49
-
-
- In article <7240@skye.ed.ac.uk> ken@aiai.ed.ac.uk (Ken Johnson) writes:
-
- Path: nmsu.edu!lynx!umn.edu!umeecs!caen!uunet!mcsun!uknet!edcastle!aiai!ken
- From: ken@aiai.ed.ac.uk (Ken Johnson)
- Newsgroups: comp.lang.prolog
- Keywords: singleton
- Date: 18 Aug 92 17:16:03 GMT
- References: <1992Aug17.172126.19111@watson.ibm.com> <5100@sersun1.essex.ac.uk>
- Followup-To: comp.lang.prolog
- Organization: Bugs-R-Us
- Lines: 30
-
- In article <5100@sersun1.essex.ac.uk> palmm@essex.ac.uk (Palmer M J)
- writes:
-
- # Some systems (e.g. Qunitus Prolog) allow you to use the form _VarName.
- # This is still an anonymous variable but with a name. You might like to
- # try this.
-
- Forgive my pedantry, but (in Edinburgh Prolog) ocurrences of variables
- with the same name are equal to each other, even if the name begins with
- _. So _A and _B, etc., are not anonymous variables. The point is that
- the singleton variable check is not applied to such variable names.
-
-
- this isn't pedantry, it is error. each occurence of _ *is* an
- anonymous variable. it is true that _A is *not* anonymous.
-
- for example:
-
- Quintus Prolog Release 3.1.1 (Sun-4, SunOS 4.1)
- Copyright (C) 1990, Quintus Corporation. All rights reserved.
- 2100 Geng Road, Palo Alto, California U.S.A. (415) 813-3800
-
- | ?- [user].
- | diff(_,_).
- | diff2(_A,_A).
- |
- % user compiled in module user, 0.033 sec 188 bytes
-
- yes
- | ?- diff(2,3).
-
- yes
- | ?- diff2(2,3).
-
- no
- | ?-
-