Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
QmlIR::IRBuilder Struct Reference

#include <qqmlirbuilder_p.h>

+ Inheritance diagram for QmlIR::IRBuilder:
+ Collaboration diagram for QmlIR::IRBuilder:

Public Member Functions

 IRBuilder (const QSet< QString > &illegalNames)
 
bool generateFromQml (const QString &code, const QString &url, Document *output)
 
bool visit (QQmlJS::AST::UiArrayMemberList *ast) override
 
bool visit (QQmlJS::AST::UiImport *ast) override
 
bool visit (QQmlJS::AST::UiPragma *ast) override
 
bool visit (QQmlJS::AST::UiHeaderItemList *ast) override
 
bool visit (QQmlJS::AST::UiObjectInitializer *ast) override
 
bool visit (QQmlJS::AST::UiObjectMemberList *ast) override
 
bool visit (QQmlJS::AST::UiParameterList *ast) override
 
bool visit (QQmlJS::AST::UiProgram *) override
 
bool visit (QQmlJS::AST::UiQualifiedId *ast) override
 
bool visit (QQmlJS::AST::UiArrayBinding *ast) override
 
bool visit (QQmlJS::AST::UiObjectBinding *ast) override
 
bool visit (QQmlJS::AST::UiObjectDefinition *ast) override
 
bool visit (QQmlJS::AST::UiInlineComponent *ast) override
 
bool visit (QQmlJS::AST::UiEnumDeclaration *ast) override
 
bool visit (QQmlJS::AST::UiPublicMember *ast) override
 
bool visit (QQmlJS::AST::UiScriptBinding *ast) override
 
bool visit (QQmlJS::AST::UiSourceElement *ast) override
 
bool visit (QQmlJS::AST::UiRequired *ast) override
 
void throwRecursionDepthError () override
 
void accept (QQmlJS::AST::Node *node)
 
bool defineQMLObject (int *objectIndex, QQmlJS::AST::UiQualifiedId *qualifiedTypeNameId, const QV4::CompiledData::Location &location, QQmlJS::AST::UiObjectInitializer *initializer, Object *declarationsOverride=nullptr)
 
bool defineQMLObject (int *objectIndex, QQmlJS::AST::UiObjectDefinition *node, Object *declarationsOverride=nullptr)
 
QStringView asStringRef (QQmlJS::AST::Node *node)
 
QStringView textRefAt (const QQmlJS::SourceLocation &loc) const
 
QStringView textRefAt (const QQmlJS::SourceLocation &first, const QQmlJS::SourceLocation &last) const
 
void setBindingValue (QV4::CompiledData::Binding *binding, QQmlJS::AST::Statement *statement, QQmlJS::AST::Node *parentNode)
 
void tryGeneratingTranslationBinding (QStringView base, QQmlJS::AST::ArgumentList *args, QV4::CompiledData::Binding *binding)
 
void appendBinding (QQmlJS::AST::UiQualifiedId *name, QQmlJS::AST::Statement *value, QQmlJS::AST::Node *parentNode)
 
void appendBinding (QQmlJS::AST::UiQualifiedId *name, int objectIndex, bool isOnAssignment=false)
 
void appendBinding (const QQmlJS::SourceLocation &qualifiedNameLocation, const QQmlJS::SourceLocation &nameLocation, quint32 propertyNameIndex, QQmlJS::AST::Statement *value, QQmlJS::AST::Node *parentNode)
 
void appendBinding (const QQmlJS::SourceLocation &qualifiedNameLocation, const QQmlJS::SourceLocation &nameLocation, quint32 propertyNameIndex, int objectIndex, bool isListItem=false, bool isOnAssignment=false)
 
bool appendAlias (QQmlJS::AST::UiPublicMember *node)
 
ObjectbindingsTarget () const
 
bool setId (const QQmlJS::SourceLocation &idLocation, QQmlJS::AST::Statement *value)
 
bool resolveQualifiedId (QQmlJS::AST::UiQualifiedId **nameToResolve, Object **object, bool onAssignment=false)
 
void recordError (const QQmlJS::SourceLocation &location, const QString &description)
 
quint32 registerString (const QString &str) const
 
template<typename _Tp >
_Tp * New ()
 
QString stringAt (int index) const
 
QString sanityCheckFunctionNames (Object *obj, const QSet< QString > &illegalNames, QQmlJS::SourceLocation *errorLocation)
 
- Public Member Functions inherited from QQmlJS::AST::Visitor
 Visitor (quint16 parentRecursionDepth=0)
 
bool preVisit (Node *) override
 
void postVisit (Node *) override
 
- Public Member Functions inherited from QQmlJS::AST::BaseVisitor
 BaseVisitor (quint16 parentRecursionDepth=0)
 
virtual ~BaseVisitor ()
 
virtual bool preVisit (Node *)=0
 
virtual void postVisit (Node *)=0
 
virtual QQmlJSASTClassListToVisit void throwRecursionDepthError ()=0
 
quint16 recursionDepth () const
 

Static Public Member Functions

static bool isSignalPropertyName (const QString &name)
 
static QString signalNameFromSignalPropertyName (const QString &signalPropertyName)
 
static QString asString (QQmlJS::AST::UiQualifiedId *node)
 
static QTypeRevision extractVersion (QStringView string)
 
static bool isStatementNodeScript (QQmlJS::AST::Statement *statement)
 
static bool isRedundantNullInitializerForPropertyDeclaration (Property *property, QQmlJS::AST::Statement *statement)
 

Public Attributes

QList< QQmlJS::DiagnosticMessageerrors
 
QSet< QStringillegalNames
 
QSet< QStringinlineComponentsNames
 
QList< const QV4::CompiledData::Import * > _imports
 
QList< Pragma * > _pragmas
 
QVector< Object * > _objects
 
QV4::CompiledData::TypeReferenceMap _typeReferences
 
Object_object
 
Property_propertyDeclaration
 
QQmlJS::MemoryPoolpool
 
QString sourceCode
 
QV4::Compiler::JSUnitGeneratorjsGenerator
 
bool insideInlineComponent = false
 

Additional Inherited Members

- Protected Attributes inherited from QQmlJS::AST::BaseVisitor
quint16 m_recursionDepth = 0
 

Detailed Description

Definition at line 502 of file qqmlirbuilder_p.h.

Constructor & Destructor Documentation

◆ IRBuilder()

IRBuilder::IRBuilder ( const QSet< QString > &  illegalNames)

Definition at line 369 of file qqmlirbuilder.cpp.

Member Function Documentation

◆ accept()

void IRBuilder::accept ( QQmlJS::AST::Node node)

Definition at line 633 of file qqmlirbuilder.cpp.

References QQmlJS::AST::Node::accept().

Referenced by defineQMLObject(), and generateFromQml().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ appendAlias()

bool IRBuilder::appendAlias ( QQmlJS::AST::UiPublicMember node)

Definition at line 1419 of file qqmlirbuilder.cpp.

References _object, QmlIR::Object::appendAlias(), astNodeToStringList(), QQmlJS::AST::UiPublicMember::binding, QV4::CompiledData::Alias::clearFlags(), COMPILE_EXCEPTION, QSet< T >::contains(), QQmlJS::AST::UiPublicMember::defaultToken(), emptyStringIndex, error, QQmlJS::AST::Node::firstSourceLocation(), QQmlJS::AST::UiPublicMember::firstSourceLocation(), QQmlJS::AST::UiObjectMember::firstSourceLocation(), QQmlJS::AST::UiPublicMember::identifierToken, illegalNames, QQmlJS::AST::UiPublicMember::isDefaultMember(), QV4::CompiledData::Alias::IsReadOnly, QQmlJS::AST::UiPublicMember::isReadonly(), isStatementNodeScript(), QV4::CompiledData::Alias::location, QQmlJS::AST::UiPublicMember::name, QV4::CompiledData::Alias::propertyNameIndex, recordError(), QV4::CompiledData::Alias::referenceLocation, registerString(), QQmlJS::AST::UiPublicMember::semicolonToken, QV4::CompiledData::Location::set(), QV4::CompiledData::Alias::setFlag(), QV4::CompiledData::Alias::setIdIndex(), QV4::CompiledData::Alias::setNameIndex(), QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, QQmlJS::AST::UiPublicMember::statement, QStringView::toString(), and tr.

Referenced by visit().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ appendBinding() [1/4]

◆ appendBinding() [2/4]

void IRBuilder::appendBinding ( const QQmlJS::SourceLocation qualifiedNameLocation,
const QQmlJS::SourceLocation nameLocation,
quint32  propertyNameIndex,
QQmlJS::AST::Statement value,
QQmlJS::AST::Node parentNode 
)

◆ appendBinding() [3/4]

void IRBuilder::appendBinding ( QQmlJS::AST::UiQualifiedId name,
int  objectIndex,
bool  isOnAssignment = false 
)

Definition at line 1355 of file qqmlirbuilder.cpp.

References _object, appendBinding(), qSwap(), registerString(), and resolveQualifiedId().

+ Here is the call graph for this function:

◆ appendBinding() [4/4]

void IRBuilder::appendBinding ( QQmlJS::AST::UiQualifiedId name,
QQmlJS::AST::Statement value,
QQmlJS::AST::Node parentNode 
)

Definition at line 1340 of file qqmlirbuilder.cpp.

References _object, appendBinding(), qSwap(), registerString(), resolveQualifiedId(), and setId().

Referenced by appendBinding(), appendBinding(), visit(), visit(), visit(), visit(), and visit().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ asString()

QString IRBuilder::asString ( QQmlJS::AST::UiQualifiedId node)
static

Definition at line 1206 of file qqmlirbuilder.cpp.

References it.

Referenced by defineQMLObject(), QQmlJSTypeResolver::typeFromAST(), visit(), and visit().

+ Here is the caller graph for this function:

◆ asStringRef()

QStringView IRBuilder::asStringRef ( QQmlJS::AST::Node node)

Definition at line 1220 of file qqmlirbuilder.cpp.

References QQmlJS::AST::Node::firstSourceLocation(), QQmlJS::AST::Node::lastSourceLocation(), and textRefAt().

Referenced by setBindingValue(), and setId().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ bindingsTarget()

Object * IRBuilder::bindingsTarget ( ) const

Definition at line 1490 of file qqmlirbuilder.cpp.

References _object, _propertyDeclaration, and QmlIR::Object::declarationsOverride.

Referenced by appendBinding(), appendBinding(), setBindingValue(), and visit().

+ Here is the caller graph for this function:

◆ defineQMLObject() [1/2]

bool QmlIR::IRBuilder::defineQMLObject ( int *  objectIndex,
QQmlJS::AST::UiObjectDefinition node,
Object declarationsOverride = nullptr 
)
inline

Definition at line 548 of file qqmlirbuilder_p.h.

References QQmlJS::AST::UiQualifiedId::firstSourceLocation(), QQmlJS::AST::UiObjectDefinition::initializer, and QQmlJS::AST::UiObjectDefinition::qualifiedTypeNameId.

+ Here is the call graph for this function:

◆ defineQMLObject() [2/2]

bool IRBuilder::defineQMLObject ( int *  objectIndex,
QQmlJS::AST::UiQualifiedId qualifiedTypeNameId,
const QV4::CompiledData::Location location,
QQmlJS::AST::UiObjectInitializer initializer,
Object declarationsOverride = nullptr 
)

Definition at line 638 of file qqmlirbuilder.cpp.

References _object, _objects, _propertyDeclaration, accept(), asString(), QmlIR::Object::declarationsOverride, emptyStringIndex, error, errors, QmlIR::Object::flags, illegalNames, QmlIR::Object::init(), insideInlineComponent, QList< T >::isEmpty(), QV4::CompiledData::Object::IsPartOfInlineComponent, pool, qSwap(), recordError(), registerString(), sanityCheckFunctionNames(), and tr.

Referenced by generateFromQml(), resolveQualifiedId(), visit(), visit(), visit(), and visit().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ extractVersion()

QTypeRevision IRBuilder::extractVersion ( QStringView  string)
static

Definition at line 1228 of file qqmlirbuilder.cpp.

References dot(), QTypeRevision::fromMajorVersion(), QTypeRevision::fromVersion(), and toInt().

Referenced by QmlIR::ScriptDirectivesCollector::importModule().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ generateFromQml()

bool IRBuilder::generateFromQml ( const QString code,
const QString url,
Document output 
)

Definition at line 378 of file qqmlirbuilder.cpp.

References _imports, _objects, _pragmas, accept(), defineQMLObject(), emptyStringIndex, errors, QList< T >::isEmpty(), QmlIR::Document::jsGenerator, jsGenerator, QmlIR::Document::jsParserEngine, output, pool, QQmlJS::Engine::pool(), Q_ASSERT, qPrintable, qSwap(), qWarning, recordError(), registerString(), QQmlJS::Lexer::setCode(), sourceCode, QCoreApplication::translate(), and url.

Referenced by qCompileQmlFile().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isRedundantNullInitializerForPropertyDeclaration()

bool IRBuilder::isRedundantNullInitializerForPropertyDeclaration ( Property property,
QQmlJS::AST::Statement statement 
)
static

Definition at line 1656 of file qqmlirbuilder.cpp.

References QQmlJS::AST::ExpressionStatement::expression, and property.

Referenced by visit().

+ Here is the caller graph for this function:

◆ isSignalPropertyName()

bool IRBuilder::isSignalPropertyName ( const QString name)
static

Definition at line 445 of file qqmlirbuilder.cpp.

References i, QChar::isUpper(), and QChar::unicode().

Referenced by QQuickPropertyChangesPrivate::decodeBinding(), QQmlPropertyPrivate::initProperty(), and QQmlJSFunctionInitializer::run().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isStatementNodeScript()

bool IRBuilder::isStatementNodeScript ( QQmlJS::AST::Statement statement)
static

Definition at line 1631 of file qqmlirbuilder.cpp.

References QQmlJS::AST::Node::kind, QQmlJS::AST::Node::Kind_FalseLiteral, and QQmlJS::AST::Node::Kind_TrueLiteral.

Referenced by appendAlias().

+ Here is the caller graph for this function:

◆ New()

template<typename _Tp >
_Tp * QmlIR::IRBuilder::New ( )
inline

Definition at line 594 of file qqmlirbuilder_p.h.

References pool.

◆ recordError()

void IRBuilder::recordError ( const QQmlJS::SourceLocation location,
const QString description 
)

Definition at line 1623 of file qqmlirbuilder.cpp.

References error, and errors.

Referenced by appendAlias(), appendBinding(), appendBinding(), defineQMLObject(), generateFromQml(), resolveQualifiedId(), PragmaParser< Argument >::run(), visit(), visit(), visit(), visit(), visit(), visit(), and visit().

+ Here is the caller graph for this function:

◆ registerString()

quint32 QmlIR::IRBuilder::registerString ( const QString str) const
inline

Definition at line 593 of file qqmlirbuilder_p.h.

References str.

Referenced by appendAlias(), appendBinding(), appendBinding(), defineQMLObject(), generateFromQml(), resolveQualifiedId(), setBindingValue(), setId(), tryGeneratingTranslationBinding(), visit(), visit(), visit(), visit(), visit(), visit(), and visit().

+ Here is the caller graph for this function:

◆ resolveQualifiedId()

bool IRBuilder::resolveQualifiedId ( QQmlJS::AST::UiQualifiedId **  nameToResolve,
Object **  object,
bool  onAssignment = false 
)

Definition at line 1544 of file qqmlirbuilder.cpp.

References _imports, _object, _objects, QV4::CompiledData::Binding::clearFlags(), COMPILE_EXCEPTION, QStringView::data(), defineQMLObject(), emptyStringIndex, error, QQmlJS::AST::UiQualifiedId::firstSourceLocation(), QQmlJS::AST::UiQualifiedId::identifierToken, QV4::CompiledData::Binding::isAttachedProperty(), QV4::CompiledData::Binding::isGroupProperty(), QV4::CompiledData::Binding::IsOnAssignment, QChar::isUpper(), QV4::CompiledData::Binding::location, QQmlJS::AST::UiQualifiedId::name, QQmlJS::AST::UiQualifiedId::next, QV4::CompiledData::Binding::objectIndex, QQmlJS::SourceLocation::offset, QmlIR::Binding::offset, QV4::CompiledData::Binding::propertyNameIndex, Q_ASSERT, recordError(), registerString(), QV4::CompiledData::Location::set(), QV4::CompiledData::Binding::setFlag(), QV4::CompiledData::Binding::setType(), QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, stringAt(), QStringView::toString(), tr, QV4::CompiledData::Binding::Type_AttachedProperty, QV4::CompiledData::Binding::Type_GroupProperty, QV4::CompiledData::Binding::value, and QV4::CompiledData::Binding::valueLocation.

Referenced by appendBinding(), appendBinding(), and visit().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ sanityCheckFunctionNames()

QString IRBuilder::sanityCheckFunctionNames ( Object obj,
const QSet< QString > &  illegalNames,
QQmlJS::SourceLocation errorLocation 
)

Definition at line 134 of file qqmlirbuilder.cpp.

References QSet< T >::contains(), illegalNames, QSet< T >::insert(), QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, stringAt(), and tr.

Referenced by defineQMLObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setBindingValue()

void IRBuilder::setBindingValue ( QV4::CompiledData::Binding binding,
QQmlJS::AST::Statement statement,
QQmlJS::AST::Node parentNode 
)

Definition at line 1244 of file qqmlirbuilder.cpp.

References _propertyDeclaration, asStringRef(), QV4::CompiledData::Binding::b, base, bindingsTarget(), QV4::CompiledData::Binding::compiledScriptIndex, QV4::CompiledData::Binding::constantValueIndex, emptyStringIndex, QQmlJS::AST::ExpressionStatement::expression, QQmlJS::AST::Node::firstSourceLocation(), QmlIR::Object::functionsAndExpressions, QQmlJS::AST::TemplateLiteral::hasNoSubstitution, QV4::CompiledData::Binding::InitializerForReadOnlyDeclaration, QV4::CompiledData::Binding::IsFunctionExpression, QV4::CompiledData::Property::isReadOnly(), jsGenerator, QQmlJS::AST::Node::kind, QQmlJS::AST::Node::Kind_FalseLiteral, QQmlJS::AST::Node::Kind_TrueLiteral, QmlIR::CompiledFunctionOrExpression::nameIndex, QmlIR::CompiledFunctionOrExpression::node, QV4::CompiledData::Binding::nullMarker, QmlIR::CompiledFunctionOrExpression::parentNode, QV4::CompiledData::Binding::propertyNameIndex, QV4::Compiler::JSUnitGenerator::registerConstant(), registerString(), QV4::CompiledData::Location::set(), QV4::CompiledData::Binding::setFlag(), QV4::CompiledData::Binding::setType(), QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, stringAt(), QV4::CompiledData::Binding::stringIndex, tryGeneratingTranslationBinding(), QV4::CompiledData::Binding::type(), QV4::CompiledData::Binding::Type_Boolean, QV4::CompiledData::Binding::Type_Invalid, QV4::CompiledData::Binding::Type_Null, QV4::CompiledData::Binding::Type_Number, QV4::CompiledData::Binding::Type_Script, QV4::CompiledData::Binding::Type_String, QV4::CompiledData::Binding::value, and QV4::CompiledData::Binding::valueLocation.

Referenced by appendBinding().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setId()

bool IRBuilder::setId ( const QQmlJS::SourceLocation idLocation,
QQmlJS::AST::Statement value 
)

Definition at line 1497 of file qqmlirbuilder.cpp.

References _object, asStringRef(), QString::at(), ch, COMPILE_EXCEPTION, QSet< T >::contains(), emptyStringIndex, QmlIR::Object::idNameIndex, illegalNames, QString::isEmpty(), QmlIR::Object::locationOfIdProperty, registerString(), QV4::CompiledData::Location::set(), QString::size(), QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, str, and tr.

Referenced by appendBinding().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ signalNameFromSignalPropertyName()

QString IRBuilder::signalNameFromSignalPropertyName ( const QString signalPropertyName)
static

Definition at line 459 of file qqmlirbuilder.cpp.

References QString::at(), QChar::isUpper(), Q_ASSERT, QString::remove(), QString::size(), QString::startsWith(), and QChar::toLower().

Referenced by QQmlJSFunctionInitializer::run().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ stringAt()

QString QmlIR::IRBuilder::stringAt ( int  index) const
inline

Definition at line 596 of file qqmlirbuilder_p.h.

Referenced by appendBinding(), resolveQualifiedId(), sanityCheckFunctionNames(), and setBindingValue().

+ Here is the caller graph for this function:

◆ textRefAt() [1/2]

QStringView IRBuilder::textRefAt ( const QQmlJS::SourceLocation first,
const QQmlJS::SourceLocation last 
) const

Definition at line 1239 of file qqmlirbuilder.cpp.

References QQmlJS::SourceLocation::length, QStringView::mid(), QQmlJS::SourceLocation::offset, and sourceCode.

+ Here is the call graph for this function:

◆ textRefAt() [2/2]

QStringView QmlIR::IRBuilder::textRefAt ( const QQmlJS::SourceLocation loc) const
inline

Definition at line 562 of file qqmlirbuilder_p.h.

References QQmlJS::SourceLocation::length, QStringView::mid(), and QQmlJS::SourceLocation::offset.

Referenced by asStringRef().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ throwRecursionDepthError()

void QmlIR::IRBuilder::throwRecursionDepthError ( )
inlineoverridevirtual

Implements QQmlJS::AST::BaseVisitor.

Definition at line 534 of file qqmlirbuilder_p.h.

References QStringLiteral.

◆ tryGeneratingTranslationBinding()

void IRBuilder::tryGeneratingTranslationBinding ( QStringView  base,
QQmlJS::AST::ArgumentList args,
QV4::CompiledData::Binding binding 
)

Definition at line 1317 of file qqmlirbuilder.cpp.

References args, base, jsGenerator, QV4::Compiler::JSUnitGenerator::registerString(), registerString(), QV4::Compiler::JSUnitGenerator::registerTranslation(), QV4::CompiledData::Binding::setType(), QV4::CompiledData::Binding::stringIndex, toString(), QV4::CompiledData::Binding::translationDataIndex, QmlIR::tryGeneratingTranslationBindingBase(), QV4::CompiledData::Binding::Type_String, QV4::CompiledData::Binding::Type_Translation, QV4::CompiledData::Binding::Type_TranslationById, and QV4::CompiledData::Binding::value.

Referenced by setBindingValue().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ visit() [1/18]

◆ visit() [2/18]

bool IRBuilder::visit ( QQmlJS::AST::UiArrayMemberList ast)
override

Definition at line 477 of file qqmlirbuilder.cpp.

◆ visit() [3/18]

◆ visit() [4/18]

bool IRBuilder::visit ( QQmlJS::AST::UiHeaderItemList ast)
override

Definition at line 608 of file qqmlirbuilder.cpp.

References list.

◆ visit() [5/18]

◆ visit() [6/18]

◆ visit() [7/18]

bool IRBuilder::visit ( QQmlJS::AST::UiObjectBinding ast)
override

Definition at line 553 of file qqmlirbuilder.cpp.

References appendBinding(), defineQMLObject(), QQmlJS::AST::UiQualifiedId::firstSourceLocation(), QQmlJS::AST::UiObjectBinding::hasOnToken, QQmlJS::AST::UiObjectBinding::initializer, QQmlJS::AST::UiObjectBinding::qualifiedId, and QQmlJS::AST::UiObjectBinding::qualifiedTypeNameId.

+ Here is the call graph for this function:

◆ visit() [8/18]

◆ visit() [9/18]

bool IRBuilder::visit ( QQmlJS::AST::UiObjectInitializer ast)
override

Definition at line 613 of file qqmlirbuilder.cpp.

◆ visit() [10/18]

bool IRBuilder::visit ( QQmlJS::AST::UiObjectMemberList ast)
override

Definition at line 618 of file qqmlirbuilder.cpp.

◆ visit() [11/18]

bool IRBuilder::visit ( QQmlJS::AST::UiParameterList ast)
override

Definition at line 623 of file qqmlirbuilder.cpp.

◆ visit() [12/18]

bool IRBuilder::visit ( QQmlJS::AST::UiPragma ast)
override

◆ visit() [13/18]

bool IRBuilder::visit ( QQmlJS::AST::UiProgram )
override

Definition at line 482 of file qqmlirbuilder.cpp.

References Q_ASSERT.

◆ visit() [14/18]

bool IRBuilder::visit ( QQmlJS::AST::UiPublicMember ast)
override

Definition at line 1035 of file qqmlirbuilder.cpp.

References _object, _propertyDeclaration, QQmlJS::AST::Node::accept(), QString::append(), appendAlias(), appendBinding(), QmlIR::Object::appendProperty(), QmlIR::Object::appendSignal(), asString(), QQmlJS::AST::UiPublicMember::binding, ch, COMPILE_EXCEPTION, QSet< T >::contains(), QQmlJS::AST::UiPublicMember::defaultToken(), error, QQmlJS::AST::UiPublicMember::firstSourceLocation(), QQmlJS::AST::UiPublicMember::identifierToken, illegalNames, QmlIR::Parameter::initType(), QV4::CompiledData::Invalid, QQmlJS::AST::UiPublicMember::isDefaultMember(), QStringView::isEmpty(), QQmlJS::AST::UiPublicMember::isReadonly(), isRedundantNullInitializerForPropertyDeclaration(), QQmlJS::AST::UiPublicMember::isRequired(), QQmlJS::AST::UiPublicMember::memberType, QQmlJS::AST::UiPublicMember::name, QV4::CompiledData::Property::nameIndex, QQmlJS::AST::UiPublicMember::parameters, property, qSwap(), recordError(), registerString(), signal, QQmlJS::AST::UiPublicMember::Signal, QQmlJS::SourceLocation::startColumn, QQmlJS::SourceLocation::startLine, QQmlJS::AST::UiPublicMember::statement, str, QmlIR::Parameter::stringToBuiltinType(), QStringView::toString(), tr, QCoreApplication::translate(), QQmlJS::AST::UiPublicMember::type, QQmlJS::AST::UiPublicMember::typeModifier, QQmlJS::AST::UiPublicMember::typeModifierToken, and QQmlJS::AST::UiPublicMember::typeToken.

+ Here is the call graph for this function:

◆ visit() [15/18]

bool IRBuilder::visit ( QQmlJS::AST::UiQualifiedId ast)
override

Definition at line 628 of file qqmlirbuilder.cpp.

◆ visit() [16/18]

bool IRBuilder::visit ( QQmlJS::AST::UiRequired ast)
override

Definition at line 1198 of file qqmlirbuilder.cpp.

References _object, QmlIR::Object::appendRequiredPropertyExtraData(), QQmlJS::AST::UiRequired::name, registerString(), and QStringView::toString().

+ Here is the call graph for this function:

◆ visit() [17/18]

bool IRBuilder::visit ( QQmlJS::AST::UiScriptBinding ast)
override

Definition at line 565 of file qqmlirbuilder.cpp.

References appendBinding(), QQmlJS::AST::UiScriptBinding::qualifiedId, and QQmlJS::AST::UiScriptBinding::statement.

+ Here is the call graph for this function:

◆ visit() [18/18]

Member Data Documentation

◆ _imports

QList<const QV4::CompiledData::Import *> QmlIR::IRBuilder::_imports

Definition at line 608 of file qqmlirbuilder_p.h.

Referenced by generateFromQml(), resolveQualifiedId(), and visit().

◆ _object

◆ _objects

QVector<Object*> QmlIR::IRBuilder::_objects

◆ _pragmas

QList<Pragma*> QmlIR::IRBuilder::_pragmas

Definition at line 609 of file qqmlirbuilder_p.h.

Referenced by generateFromQml(), and visit().

◆ _propertyDeclaration

Property* QmlIR::IRBuilder::_propertyDeclaration

◆ _typeReferences

QV4::CompiledData::TypeReferenceMap QmlIR::IRBuilder::_typeReferences

Definition at line 612 of file qqmlirbuilder_p.h.

◆ errors

QList<QQmlJS::DiagnosticMessage> QmlIR::IRBuilder::errors

Definition at line 603 of file qqmlirbuilder_p.h.

Referenced by defineQMLObject(), generateFromQml(), qCompileQmlFile(), and recordError().

◆ illegalNames

QSet<QString> QmlIR::IRBuilder::illegalNames

◆ inlineComponentsNames

QSet<QString> QmlIR::IRBuilder::inlineComponentsNames

Definition at line 606 of file qqmlirbuilder_p.h.

Referenced by visit().

◆ insideInlineComponent

bool QmlIR::IRBuilder::insideInlineComponent = false

Definition at line 621 of file qqmlirbuilder_p.h.

Referenced by defineQMLObject(), and visit().

◆ jsGenerator

QV4::Compiler::JSUnitGenerator* QmlIR::IRBuilder::jsGenerator

◆ pool

QQmlJS::MemoryPool* QmlIR::IRBuilder::pool

Definition at line 617 of file qqmlirbuilder_p.h.

Referenced by defineQMLObject(), generateFromQml(), and visit().

◆ sourceCode

QString QmlIR::IRBuilder::sourceCode

Definition at line 618 of file qqmlirbuilder_p.h.

Referenced by generateFromQml(), and textRefAt().


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