Executor for Conditional Macros.
bool applyMacro(Node &node, unsigned depth) override
bool canHandle(Node &node) override
void applyMacroProxy(Node &node, unsigned depth)
Apply a macro on a given node.
Node evaluate(Node &node, unsigned depth, bool is_not_body) const
Evaluate only the macros.
bool isTruthy(const Node &node) const
Check if a node can be evaluated to true.
void handleMacroNode(Node &node) const
Registers macros based on their type, expand conditional macros.
A node of an Abstract Syntax Tree for ArkScript.
NodeType nodeType() const noexcept
Return the node type.
void setNodeType(NodeType type) noexcept
Set the Node Type object.
const std::vector< Node > & constList() const noexcept
Return the list of sub-nodes held by the node.
void updateValueAndType(const Node &source) noexcept
Copy a node to the current one, while keeping the filename and position in the file.
std::vector< Node > & list() noexcept
Return the list of sub-nodes held by the node.
const Node & getNilNode()