Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <glslsemantic_p.h>
Classes | |
struct | ExprResult |
Public Member Functions | |
Semantic () | |
~Semantic () override | |
void | translationUnit (TranslationUnitAST *ast, Scope *globalScope, Engine *engine) |
ExprResult | expression (ExpressionAST *ast, Scope *scope, Engine *engine) |
Definition at line 25 of file glslsemantic_p.h.
Semantic::Semantic | ( | ) |
Definition at line 15 of file glslsemantic.cpp.
|
override |
Definition at line 22 of file glslsemantic.cpp.
|
protected |
Definition at line 63 of file glslsemantic.cpp.
References GLSL::Visitor::accept().
Referenced by translationUnit(), visit(), visit(), and visit().
|
protected |
Definition at line 40 of file glslsemantic.cpp.
References GLSL::Visitor::accept(), and GLSL::Engine::undefinedType().
Semantic::ExprResult Semantic::expression | ( | ExpressionAST * | ast, |
Scope * | scope, | ||
Engine * | engine ) |
Definition at line 82 of file glslsemantic.cpp.
References engine, expression(), switchEngine(), switchScope(), and void.
Referenced by expression(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), visit(), and visit().
|
protected |
Definition at line 117 of file glslsemantic.cpp.
References GLSL::StructTypeAST::Field::name, GLSL::Engine::newVariable(), and GLSL::StructTypeAST::Field::type.
Referenced by visit().
|
protected |
Definition at line 95 of file glslsemantic.cpp.
References GLSL::Engine::error(), QString::fromLatin1(), GLSL::AST::lineno, GLSL::Scope::lookup(), GLSL::FunctionIdentifierAST::name, and GLSL::FunctionIdentifierAST::type.
Referenced by visit().
Definition at line 285 of file glslsemantic.cpp.
References GLSL::Type::asFloatType(), GLSL::Type::asIntType(), GLSL::MatrixType::asMatrixType(), GLSL::Type::asUIntType(), and GLSL::VectorType::asVectorType().
Referenced by visit().
|
protected |
Definition at line 127 of file glslsemantic.cpp.
References arg, fun, GLSL::ParameterDeclarationAST::name, GLSL::Engine::newArgument(), and GLSL::ParameterDeclarationAST::type.
Referenced by visit().
|
protected |
Definition at line 49 of file glslsemantic.cpp.
References GLSL::Visitor::accept().
Referenced by visit(), visit(), visit(), visit(), visit(), visit(), and visit().
Definition at line 26 of file glslsemantic.cpp.
References engine.
Referenced by expression(), and translationUnit().
Definition at line 33 of file glslsemantic.cpp.
Referenced by expression(), translationUnit(), visit(), visit(), and visit().
void Semantic::translationUnit | ( | TranslationUnitAST * | ast, |
Scope * | globalScope, | ||
Engine * | engine ) |
Definition at line 68 of file glslsemantic.cpp.
References declaration(), GLSL::TranslationUnitAST::declarations, engine, it, switchEngine(), switchScope(), and void.
Definition at line 54 of file glslsemantic.cpp.
References GLSL::Visitor::accept(), and GLSL::Engine::undefinedType().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 731 of file glslsemantic.cpp.
References GLSL::Engine::arrayType(), GLSL::ArrayTypeAST::elementType, expression(), Q_UNUSED, and GLSL::ArrayTypeAST::size.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 257 of file glslsemantic.cpp.
References expression(), GLSL::AssignmentExpressionAST::value, and GLSL::AssignmentExpressionAST::variable.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 488 of file glslsemantic.cpp.
References GLSL::Engine::boolType(), GLSL::Engine::doubleType(), GLSL::Engine::error(), GLSL::Engine::floatType(), QString::fromLatin1(), GLSL::Engine::intType(), GLSL::AST::lineno, GLSL::Engine::matrixType(), GLSL::Engine::samplerType(), GLSLParserTable::spell, GLSLParserTable::T_BOOL, GLSLParserTable::T_BVEC2, GLSLParserTable::T_BVEC3, GLSLParserTable::T_BVEC4, GLSLParserTable::T_DMAT2, GLSLParserTable::T_DMAT2X2, GLSLParserTable::T_DMAT2X3, GLSLParserTable::T_DMAT2X4, GLSLParserTable::T_DMAT3, GLSLParserTable::T_DMAT3X2, GLSLParserTable::T_DMAT3X3, GLSLParserTable::T_DMAT3X4, GLSLParserTable::T_DMAT4, GLSLParserTable::T_DMAT4X2, GLSLParserTable::T_DMAT4X3, GLSLParserTable::T_DMAT4X4, GLSLParserTable::T_DOUBLE, GLSLParserTable::T_DVEC2, GLSLParserTable::T_DVEC3, GLSLParserTable::T_DVEC4, GLSLParserTable::T_FLOAT, GLSLParserTable::T_INT, GLSLParserTable::T_ISAMPLER1D, GLSLParserTable::T_ISAMPLER1DARRAY, GLSLParserTable::T_ISAMPLER2D, GLSLParserTable::T_ISAMPLER2DARRAY, GLSLParserTable::T_ISAMPLER2DMS, GLSLParserTable::T_ISAMPLER2DMSARRAY, GLSLParserTable::T_ISAMPLER2DRECT, GLSLParserTable::T_ISAMPLER3D, GLSLParserTable::T_ISAMPLERBUFFER, GLSLParserTable::T_ISAMPLERCUBE, GLSLParserTable::T_ISAMPLERCUBEARRAY, GLSLParserTable::T_IVEC2, GLSLParserTable::T_IVEC3, GLSLParserTable::T_IVEC4, GLSLParserTable::T_MAT2, GLSLParserTable::T_MAT2X2, GLSLParserTable::T_MAT2X3, GLSLParserTable::T_MAT2X4, GLSLParserTable::T_MAT3, GLSLParserTable::T_MAT3X2, GLSLParserTable::T_MAT3X3, GLSLParserTable::T_MAT3X4, GLSLParserTable::T_MAT4, GLSLParserTable::T_MAT4X2, GLSLParserTable::T_MAT4X3, GLSLParserTable::T_MAT4X4, GLSLParserTable::T_SAMPLER1D, GLSLParserTable::T_SAMPLER1DARRAY, GLSLParserTable::T_SAMPLER1DARRAYSHADOW, GLSLParserTable::T_SAMPLER1DSHADOW, GLSLParserTable::T_SAMPLER2D, GLSLParserTable::T_SAMPLER2DARRAY, GLSLParserTable::T_SAMPLER2DARRAYSHADOW, GLSLParserTable::T_SAMPLER2DMS, GLSLParserTable::T_SAMPLER2DMSARRAY, GLSLParserTable::T_SAMPLER2DRECT, GLSLParserTable::T_SAMPLER2DRECTSHADOW, GLSLParserTable::T_SAMPLER2DSHADOW, GLSLParserTable::T_SAMPLER3D, GLSLParserTable::T_SAMPLERBUFFER, GLSLParserTable::T_SAMPLERCUBE, GLSLParserTable::T_SAMPLERCUBEARRAY, GLSLParserTable::T_SAMPLERCUBEARRAYSHADOW, GLSLParserTable::T_SAMPLERCUBESHADOW, GLSLParserTable::T_UINT, GLSLParserTable::T_USAMPLER1D, GLSLParserTable::T_USAMPLER1DARRAY, GLSLParserTable::T_USAMPLER2D, GLSLParserTable::T_USAMPLER2DARRAY, GLSLParserTable::T_USAMPLER2DMS, GLSLParserTable::T_USAMPLER2DMSARRAY, GLSLParserTable::T_USAMPLER2DRECT, GLSLParserTable::T_USAMPLER3D, GLSLParserTable::T_USAMPLERBUFFER, GLSLParserTable::T_USAMPLERCUBE, GLSLParserTable::T_USAMPLERCUBEARRAY, GLSLParserTable::T_UVEC2, GLSLParserTable::T_UVEC3, GLSLParserTable::T_UVEC4, GLSLParserTable::T_VEC2, GLSLParserTable::T_VEC3, GLSLParserTable::T_VEC4, GLSLParserTable::T_VOID, GLSL::BasicTypeAST::token, GLSL::Engine::uintType(), GLSL::Engine::vectorType(), and GLSL::Engine::voidType().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 192 of file glslsemantic.cpp.
References GLSL::IndexType::asIndexType(), GLSL::Engine::boolType(), GLSL::Engine::error(), expression(), QString::fromLatin1(), GLSL::Semantic::ExprResult::isConstant, GLSL::AST::kind, GLSL::AST::Kind_ArrayAccess, GLSL::AST::Kind_BitwiseAnd, GLSL::AST::Kind_BitwiseOr, GLSL::AST::Kind_BitwiseXor, GLSL::AST::Kind_Comma, GLSL::AST::Kind_Divide, GLSL::AST::Kind_Equal, GLSL::AST::Kind_GreaterEqual, GLSL::AST::Kind_GreaterThan, GLSL::AST::Kind_LessEqual, GLSL::AST::Kind_LessThan, GLSL::AST::Kind_LogicalAnd, GLSL::AST::Kind_LogicalOr, GLSL::AST::Kind_LogicalXor, GLSL::AST::Kind_Minus, GLSL::AST::Kind_Modulus, GLSL::AST::Kind_Multiply, GLSL::AST::Kind_NotEqual, GLSL::AST::Kind_Plus, GLSL::AST::Kind_ShiftLeft, GLSL::AST::Kind_ShiftRight, GLSL::BinaryExpressionAST::left, GLSL::AST::lineno, GLSL::BinaryExpressionAST::right, and GLSL::Semantic::ExprResult::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 474 of file glslsemantic.cpp.
References GLSL::CaseLabelStatementAST::expr, and expression().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 411 of file glslsemantic.cpp.
References it, GLSL::Engine::newBlock(), statement(), GLSL::CompoundStatementAST::statements, switchScope(), GLSL::CompoundStatementAST::symbol, and void.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 394 of file glslsemantic.cpp.
References expression(), GLSL::DeclarationExpressionAST::initializer, Q_UNUSED, and GLSL::DeclarationExpressionAST::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 480 of file glslsemantic.cpp.
References GLSL::DeclarationStatementAST::decl, and declaration().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 439 of file glslsemantic.cpp.
References GLSL::DoStatementAST::body, GLSL::DoStatementAST::condition, expression(), and statement().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 405 of file glslsemantic.cpp.
References GLSL::ExpressionStatementAST::expr, and expression().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 446 of file glslsemantic.cpp.
References GLSL::ForStatementAST::body, GLSL::ForStatementAST::condition, expression(), increment(), GLSL::ForStatementAST::increment, GLSL::ForStatementAST::init, and statement().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 339 of file glslsemantic.cpp.
References arg, GLSL::FunctionCallExpressionAST::arguments, GLSL::Function::asFunctionType(), GLSL::OverloadSet::asOverloadSetType(), GLSL::Engine::error(), GLSL::FunctionCallExpressionAST::expr, expression(), QString::fromLatin1(), functionIdentifier(), GLSL::FunctionCallExpressionAST::id, implicitCast(), it, GLSL::AST::lineno, Q_ASSERT, and GLSL::Semantic::ExprResult::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 832 of file glslsemantic.cpp.
References GLSL::FunctionDeclarationAST::body, fun, it, GLSL::FunctionDeclarationAST::name, GLSL::Engine::newFunction(), parameterDeclaration(), GLSL::FunctionDeclarationAST::params, GLSL::FunctionDeclarationAST::returnType, statement(), switchScope(), and void.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 144 of file glslsemantic.cpp.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 160 of file glslsemantic.cpp.
References GLSL::Engine::error(), QString::fromLatin1(), GLSL::AST::lineno, GLSL::Scope::lookup(), GLSL::IdentifierExpressionAST::name, and GLSL::Semantic::ExprResult::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 424 of file glslsemantic.cpp.
References GLSL::IfStatementAST::condition, GLSL::IfStatementAST::elseClause, expression(), statement(), and GLSL::IfStatementAST::thenClause.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 823 of file glslsemantic.cpp.
References declaration(), GLSL::InitDeclarationAST::decls, and it.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 817 of file glslsemantic.cpp.
References Q_UNUSED.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 455 of file glslsemantic.cpp.
References Q_UNUSED.
|
inlineoverrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 102 of file glslsemantic_p.h.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 171 of file glslsemantic.cpp.
References QString::at(), GLSL::Engine::boolType(), QString::contains(), GLSL::Engine::doubleType(), QString::endsWith(), GLSL::Engine::floatType(), GLSL::Engine::intType(), GLSL::Semantic::ExprResult::isConstant, GLSL::Semantic::ExprResult::type, GLSL::Engine::uintType(), and GLSL::LiteralExpressionAST::value.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 264 of file glslsemantic.cpp.
References GLSL::Type::asStructType(), GLSL::Type::asVectorType(), GLSL::Engine::error(), GLSL::MemberAccessExpressionAST::expr, expression(), GLSL::MemberAccessExpressionAST::field, QString::fromLatin1(), GLSL::AST::lineno, and GLSL::Semantic::ExprResult::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 716 of file glslsemantic.cpp.
References GLSL::Struct::asStruct(), GLSL::Engine::error(), QString::fromLatin1(), GLSL::AST::lineno, GLSL::Scope::lookup(), and GLSL::NamedTypeAST::name.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 778 of file glslsemantic.cpp.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 771 of file glslsemantic.cpp.
References Q_UNUSED, and GLSL::PrecisionDeclarationAST::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 757 of file glslsemantic.cpp.
References it, GLSL::QualifiedTypeAST::layout_list, Q_UNUSED, and GLSL::QualifiedTypeAST::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 461 of file glslsemantic.cpp.
References GLSL::ReturnStatementAST::expr, and expression().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 740 of file glslsemantic.cpp.
References field(), GLSL::StructTypeAST::fields, it, GLSL::StructTypeAST::name, GLSL::Engine::newStruct(), GLSL::Symbol::scope(), GLSL::Symbol::setName(), switchScope(), and void.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 151 of file glslsemantic.cpp.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 467 of file glslsemantic.cpp.
References GLSL::SwitchStatementAST::body, GLSL::SwitchStatementAST::expr, expression(), and statement().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 247 of file glslsemantic.cpp.
References expression(), GLSL::TernaryExpressionAST::first, GLSL::Semantic::ExprResult::isConstant, GLSL::TernaryExpressionAST::second, GLSL::TernaryExpressionAST::third, and GLSL::Semantic::ExprResult::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 137 of file glslsemantic.cpp.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 810 of file glslsemantic.cpp.
References declaration(), GLSL::TypeAndVariableDeclarationAST::typeDecl, and GLSL::TypeAndVariableDeclarationAST::varDecl.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 803 of file glslsemantic.cpp.
References Q_UNUSED, and GLSL::TypeDeclarationAST::type.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 240 of file glslsemantic.cpp.
References GLSL::UnaryExpressionAST::expr, and expression().
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 785 of file glslsemantic.cpp.
References GLSL::Scope::add(), GLSL::AST::asQualifiedType(), expression(), GLSL::VariableDeclarationAST::initializer, GLSL::VariableDeclarationAST::name, GLSL::Engine::newVariable(), GLSL::VariableDeclarationAST::type, and var.
|
overrideprotectedvirtual |
Reimplemented from GLSL::Visitor.
Definition at line 432 of file glslsemantic.cpp.
References GLSL::WhileStatementAST::body, GLSL::WhileStatementAST::condition, expression(), and statement().