Namer

org.nlogo.parse.Namer
See theNamer companion object
class Namer(program: Program, procedures: ProceduresMap, procedure: FrontEndProcedure, extensionManager: ExtensionManager) extends TokenTransformer[Unit]

Classifies identifier tokens as commands or reporters.

This is basically just a function from Iterator[Token] to Iterator[Token]. Most tokens pass through unchanged, but each token of type Ident is replaced with a new token of type TokenType.Command or TokenType.Reporter.

One additional check is performed: checkProcedureName makes sure the name (and input names) of each procedure aren't also the name of anything else. (That check happens here because here is where the knowledge of what names are taken resides.)

Attributes

Companion
object
Source
Namer.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def initialState: Unit

Attributes

Definition Classes
Source
Namer.scala
override def transform(t: Token, state: Unit): (Token, Unit)

Attributes

Definition Classes
Source
Namer.scala

Attributes

Source
Namer.scala

Concrete fields

Attributes

Source
Namer.scala