Is this function defined

namep expression
name? expression

Returns true if the result of expression is a name of a variable (local, global or shared) defined in the cureent scope of program.

Example:

to model
  let "x 1
end

"y := 2

"t := (newt $model)

print name? "x
print name? "y
print (name? "x) @ :t
print (name? "y) @ :t

Output:

False
True
True
False

See also:

Table of Content