aboutsummaryrefslogtreecommitdiff
path: root/src/algebra/syntax.spad.pamphlet
diff options
context:
space:
mode:
Diffstat (limited to 'src/algebra/syntax.spad.pamphlet')
-rw-r--r--src/algebra/syntax.spad.pamphlet14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/algebra/syntax.spad.pamphlet b/src/algebra/syntax.spad.pamphlet
index 2ab38358..783459b1 100644
--- a/src/algebra/syntax.spad.pamphlet
+++ b/src/algebra/syntax.spad.pamphlet
@@ -579,27 +579,23 @@ Literal(T: SetCategory): Public == Private where
<<domain IDENT Identifier>>=
++ Author: Gabriel Dos Reis
++ Date Created: July 5, 2008
-++ Date Last Modified: April 20, 2009
+++ Date Last Modified: September 7, 2011
++ Description:
-++ This domain represents identifer AST.
-++ This domain differs from Symbol in that it does not support
-++ any form of scripting.
-++ A value of this domain is a plain old identifier.
+++ This domain provides representation for plain identifiers.
+++ It differs from Symbol in that it does not support any form
+++ of scripting. It is a plain basic data structure.
++
)abbrev domain IDENT Identifier
Identifier(): Public == Private where
- Public == Join(SetCategory, CoercibleTo Symbol, CoercibleTo String) with
+ Public == SetCategory with
gensym: () -> %
++ \spad{gensym()} returns a new identifier, different from
++ any other identifier in the running system
Private == add
import %peq: (%,%) -> Boolean from Foreign Builtin
import %gensym: () -> % from Foreign Builtin
- import %sname: % -> String from Foreign Builtin
gensym() == %gensym()
x = y == %peq(x,y)
- coerce(x: %): Symbol == x : Symbol
- coerce(x: %): String == %sname x
coerce(x: %): OutputForm == x : OutputForm
@