CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
CeresEngine::ShaderCompiler::BracketExpression Struct Reference

#include <CeresEngine/Material/ShaderCompiler/AST/AST.hpp>

Inheritance diagram for CeresEngine::ShaderCompiler::BracketExpression:
CeresEngine::ShaderCompiler::Expression CeresEngine::ShaderCompiler::TypedAST CeresEngine::ShaderCompiler::AST

Public Member Functions

 BracketExpression (const SourcePosition &astPos)
 
 BracketExpression (const SourceArea &astArea)
 
Types getType () const override
 
void visit (Visitor *visitor, void *args=nullptr) override
 
TypeDenoterPtr deriveTypeDenoter (const TypeDenoter *expectedTypeDenoter) override
 
const Expressionfind (const FindPredicateConstFunctor &predicate, UInt32 flags=SearchAll) const override
 
const ObjectExpressionfetchLValueExpression () const override
 Returns the first node in the expression tree that is an l-value (may also be constant!), or null if there is no l-value.
 
IndexedSemantic fetchSemantic () const override
 
- Public Member Functions inherited from CeresEngine::ShaderCompiler::Expression
VarDeclarationfetchVarDeclaration () const
 
ObjectExpressionfetchLValueExpression ()
 
virtual bool isTrivialCopyable (UInt32 maxTreeDepth=3) const
 
const ExpressionfindFirstOf (const Types expressionType, UInt32 flags=SearchAll) const
 
const ExpressionfindFirstNotOf (const Types expressionType, UInt32 flags=SearchAll) const
 
Expressionfind (const FindPredicateConstFunctor &predicate, UInt32 flags=SearchAll)
 
ExpressionfindFirstOf (const Types expressionType, UInt32 flags=SearchAll)
 
ExpressionfindFirstNotOf (const Types expressionType, UInt32 flags=SearchAll)
 
- Public Member Functions inherited from CeresEngine::ShaderCompiler::TypedAST
const TypeDenoterPtrgetTypeDenoter (const TypeDenoter *expectedTypeDenoter=nullptr)
 
void resetTypeDenoter ()
 
- Public Member Functions inherited from CeresEngine::ShaderCompiler::AST
virtual ~AST ()
 
template<typename T >
Tas ()
 
template<typename T >
const Tas () const
 

Public Attributes

ExpressionPtr expression
 
- Public Attributes inherited from CeresEngine::ShaderCompiler::AST
SourceArea area
 
RawFlags flags
 

Static Public Attributes

static const Types classType = Types:: BracketExpression
 

Additional Inherited Members

- Public Types inherited from CeresEngine::ShaderCompiler::Expression
enum  : UInt32 { wasConverted = (1u << ( 0 )) }
 
- Public Types inherited from CeresEngine::ShaderCompiler::AST
enum class  Types {
  Program , CodeBlock , Attribute , SwitchCase ,
  SamplerValue , Register , PackOffset , ArrayDimension ,
  TypeSpecifier , VarDeclaration , BufferDeclaration , SamplerDeclaration ,
  StructDeclaration , AliasDeclaration , FunctionDeclaration , UniformBufferDeclaration ,
  VarDeclarationStatement , BufferDeclarationStatement , SamplerDeclarationStatement , AliasDeclarationStatement ,
  BasicDeclarationStatement , NullStatement , CodeBlockStatement , ForLoopStatement ,
  WhileLoopStatement , DoWhileLoopStatement , IfStatement , ElseStatement ,
  SwitchStatement , ExpressionStatement , ReturnStatement , CtrlTransferStatement ,
  LayoutStatement , NullExpression , SequenceExpression , LiteralExpression ,
  TypeSpecifierExpression , TernaryExpression , BinaryExpression , UnaryExpression ,
  PostUnaryExpression , CallExpression , BracketExpression , ObjectExpression ,
  AssignExpression , ArrayExpression , CastExpression , InitializerExpression
}
 
enum  : UInt32 { isReachable = (1u << ( 30 )) , isDeadCode = (1u << ( 29 )) , isBuiltin = (1u << ( 28 )) }
 
- Static Public Member Functions inherited from CeresEngine::ShaderCompiler::AST
template<typename T >
static TgetAs (AST *ast)
 
template<typename T >
static const TgetAs (const AST *ast)
 

Constructor & Destructor Documentation

◆ BracketExpression() [1/2]

CeresEngine::ShaderCompiler::BracketExpression::BracketExpression ( const SourcePosition astPos)
inlineexplicit

◆ BracketExpression() [2/2]

CeresEngine::ShaderCompiler::BracketExpression::BracketExpression ( const SourceArea astArea)
inlineexplicit

Member Function Documentation

◆ deriveTypeDenoter()

TypeDenoterPtr CeresEngine::ShaderCompiler::BracketExpression::deriveTypeDenoter ( const TypeDenoter expectedTypeDenoter)
overridevirtual

◆ fetchLValueExpression()

const ObjectExpression * CeresEngine::ShaderCompiler::BracketExpression::fetchLValueExpression ( ) const
overridevirtual

Returns the first node in the expression tree that is an l-value (may also be constant!), or null if there is no l-value.

If the return value is non-null, the object expression must refer to a declaration object. By default null.

Reimplemented from CeresEngine::ShaderCompiler::Expression.

◆ fetchSemantic()

IndexedSemantic CeresEngine::ShaderCompiler::BracketExpression::fetchSemantic ( ) const
overridevirtual

◆ find()

const Expression * CeresEngine::ShaderCompiler::BracketExpression::find ( const FindPredicateConstFunctor predicate,
UInt32  flags = SearchAll 
) const
overridevirtual

◆ getType()

Types CeresEngine::ShaderCompiler::BracketExpression::getType ( ) const
inlineoverridevirtual

◆ visit()

void CeresEngine::ShaderCompiler::BracketExpression::visit ( Visitor visitor,
void args = nullptr 
)
inlineoverridevirtual

Member Data Documentation

◆ classType

const Types CeresEngine::ShaderCompiler::BracketExpression::classType = Types:: BracketExpression
static

◆ expression

ExpressionPtr CeresEngine::ShaderCompiler::BracketExpression::expression

The documentation for this struct was generated from the following file: