new Code()
- Source:
Properties:
| Name | Type | Description |
|---|---|---|
Machine |
Object | stack machine generator class. |
machine |
module:Six~Machine10 | stack machine to generate code for. |
Extends
Members
-
Instructions
-
Extended stack machine instructions.
-
Machine
-
Stack machine generator class.
-
executable
-
The executable.
-
machine
-
Stack machine generator.
Methods
-
_dump(node [, shallow])
-
Creates a deep display of a node.
Parameters:
Name Type Argument Description nodeArray to recursively traverse.
shallownumber <optional>
limits depth if non-negative, by default unlimited.
- Inherited From:
- Source:
-
_error()
-
Displays and counts an error message.
- Inherited From:
- Source:
-
_postfix(op)
-
Visits the subtrees and generates an instruction.
Parameters:
Name Type Description opstring instruction name.
Returns:
end of code memory.
- Type
- number
-
_tree(node)
-
Recursively checks tree tags, throws an error if there is a problem.
Parameters:
Name Type Description nodeArray to validate.
- Inherited From:
- Source:
-
visit(node [, trace])
-
Visits a (valid!) tree node, returns either
nodeitself or the result of calling tag as method for an array.Parameters:
Name Type Argument Description nodeArray to visit, using the tag as a method name and the node as argument.
traceRegExp <optional>
sets
.traceif specified.- Inherited From:
- Source: