| Prev
| Next
| Start of Chapter
| End of Chapter
| Contents
| Glossary
| Index
| Comments |
(13 out of 15)
Symbol Function
The symbol function converts a text expression into a symbol. You can use the result of the symbol function to name transient objects. The syntax is:
symbol (
text-expression
) = (
s
)
Caution:
Once G2 creates a symbol with the symbol function, the memory it uses cannot be reclaimed or reused within that execution of G2 even if you delete the item that uses the symbol. If a symbol with the name specified by the
text-expression
already exists, G2 reuses that symbol and does not create a new one.
G2 maps all alphabetic characters in a symbol to uppercase, even when such a character has been escaped. Thus
symbol ("abc")
creates the same symbol as
symbol ("AbC")
and
symbol ("@abc")
.
| Prev
| Next
| Start of Chapter
| End of Chapter
| Contents
| Glossary
| Index
| Comments |
(13 out of 15)
Copyright © 1997 Gensym Corporation, Inc.