BenchGen
BenchGen is a tool for generating benchmarks to stress-test a computing system.
Loading...
Searching...
No Matches
IfParam Class Reference

Represents the parameters of an if statement in the AST. More...

#include <ast.h>

Inheritance diagram for IfParam:
Collaboration diagram for IfParam:

Public Member Functions

 IfParam (std::shared_ptr< Node > code, std::shared_ptr< Node > else_)
 
void gen (Generator &) override
 Generates code for this AST node.
 
void print (int indent) override
 Prints the structure of this AST node.
 
- Public Member Functions inherited from Node
virtual ~Node ()=default
 

Detailed Description

Represents the parameters of an if statement in the AST.

Contains the code block for the if statement and the else clause.

Constructor & Destructor Documentation

◆ IfParam()

IfParam::IfParam ( std::shared_ptr< Node > code,
std::shared_ptr< Node > else_ )
inline

Member Function Documentation

◆ gen()

void IfParam::gen ( Generator & )
overridevirtual

Generates code for this AST node.

Parameters
generatorThe generator object used to manage code generation.

Implements Node.

◆ print()

void IfParam::print ( int indent)
overridevirtual

Prints the structure of this AST node.

Parameters
indentThe number of spaces to indent the output.

Implements Node.


The documentation for this class was generated from the following files: