Flutter Engine
The Flutter Engine
|
#include <SkSLIRNode.h>
Public Member Functions | |
virtual | ~IRNode () |
virtual std::string | description () const =0 |
IRNode (const IRNode &)=delete | |
IRNode & | operator= (const IRNode &)=delete |
Position | position () const |
void | setPosition (Position p) |
template<typename T > | |
bool | is () const |
template<typename T > | |
const T & | as () const |
template<typename T > | |
T & | as () |
Public Attributes | |
Position | fPosition |
Protected Member Functions | |
IRNode (Position position, int kind) | |
Protected Attributes | |
int | fKind |
Additional Inherited Members | |
Static Public Member Functions inherited from SkSL::Poolable | |
static void * | operator new (const size_t size) |
static void | operator delete (void *ptr) |
Represents a node in the intermediate representation (IR) tree. The IR is a fully-resolved version of the program (all types determined, everything validated), ready for code generation.
Definition at line 98 of file SkSLIRNode.h.
|
inlinevirtual |
Definition at line 100 of file SkSLIRNode.h.
|
delete |
Definition at line 145 of file SkSLIRNode.h.
Definition at line 139 of file SkSLIRNode.h.
Use as<T> to downcast IRNodes. e.g. replace (ReturnStatement&) s
with s.as<ReturnStatement>()
.
Definition at line 133 of file SkSLIRNode.h.
|
pure virtual |
Implemented in SkSL::Expression, SkSL::Block, SkSL::BreakStatement, SkSL::ContinueStatement, SkSL::DiscardStatement, SkSL::DoStatement, SkSL::ExpressionStatement, SkSL::Extension, SkSL::FieldSymbol, SkSL::ForStatement, SkSL::FunctionDeclaration, SkSL::FunctionDefinition, SkSL::FunctionPrototype, SkSL::IfStatement, SkSL::InterfaceBlock, SkSL::ModifiersDeclaration, SkSL::Nop, SkSL::ReturnStatement, SkSL::StructDefinition, SkSL::SwitchCase, SkSL::SwitchStatement, SkSL::Type, SkSL::VarDeclaration, SkSL::GlobalVarDeclaration, and SkSL::Variable.
|
inline |
Use is<T> to check the type of an IRNode. e.g. replace s.kind() == Statement::Kind::kReturn
with s.is<ReturnStatement>()
.
Definition at line 124 of file SkSLIRNode.h.
|
inline |
Definition at line 111 of file SkSLIRNode.h.
|
inline |
Definition at line 115 of file SkSLIRNode.h.
|
protected |
Definition at line 149 of file SkSLIRNode.h.
Position SkSL::IRNode::fPosition |
Definition at line 109 of file SkSLIRNode.h.