4#ifndef QQMLJSIMPORTEDMEMBERSVISITOR_P_H
5#define QQMLJSIMPORTEDMEMBERSVISITOR_P_H
17#include <private/qqmljscontextualtypes_p.h>
18#include <qtqmlcompilerexports.h>
26#include <QtCore/qvariant.h>
27#include <QtCore/qstack.h>
29#include <private/qqmljsast_p.h>
30#include <private/qqmljsdiagnosticmessage_p.h>
31#include <private/qv4compileddata_p.h>
48 const QString &implicitImportDirectory,
52 using QQmlJS::AST::Visitor::endVisit;
55 using QQmlJS::AST::Visitor::visit;
64 QHash<QQmlJS::SourceLocation, QQmlJSMetaSignalHandler>
signalHandlers()
const
66 return m_signalHandlers;
69 QList<QQmlJSScope::ConstPtr>
qmlTypes()
const {
return m_qmlTypes; }
72 return m_scopesByIrLocation;
75 static QString implicitImportDirectory(
154 void throwRecursionDepthError()
override;
168 bool m_nextIsInlineComponent =
false;
169 bool m_rootIsSingleton =
false;
202 return x.scope ==
y.scope &&
x.name ==
y.name;
216 bool m_thisScriptBindingIsJavaScript =
false;
222 void forgetFunctionExpression(
const QString &
name);
223 int synthesizeCompilationUnitRuntimeFunctionIndices(
const QQmlJSScope::Ptr &scope,
225 void populateRuntimeFunctionIndicesForDocument()
const;
233 void leaveEnvironment();
238 template<
typename ErrorHandler>
241 if (
type->isFullyResolved())
246 if (m_unresolvedTypes.contains(
type))
249 m_unresolvedTypes.insert(
type);
257 void setAllBindings();
258 void addDefaultProperties();
259 void processDefaultProperties();
260 void processPropertyBindings();
261 void checkRequiredProperties();
262 void processPropertyTypes();
263 void processMethodTypes();
264 void processPropertyBindingObjects();
265 void flushPendingSignalParameters();
275 BindingExpressionParseResult parseBindingExpression(
const QString &
name,
277 bool isImportPrefix(
QString prefix)
const;
349 void importBaseModules();
350 void resolveAliasesAndIds();
354 void processImportWarnings(
QQmlJSImporter::ImportedTypes imports() const
QStack< FunctionOrExpressionIdentifier > m_functionStack
QHash< QQmlJSScope::ConstPtr, QList< QString > > m_functionsAndExpressions
QMultiHash< QString, QQmlJS::SourceLocation > m_importTypeLocationMap
QQmlJSScope::Ptr m_currentScope
QMultiHash< QString, QQmlJS::SourceLocation > m_importStaticModuleLocationMap
QSet< QString > m_usedTypes
QQmlJSImporter * importer()
QQmlJS::SourceLocation m_pendingSignalHandler
QString m_implicitImportDirectory
QQmlJSScope::ConstPtr m_globalScope
QList< QQmlJSScope::ConstPtr > m_qmlTypes
const QQmlJSLogger * logger() const
QStringList m_qmldirFiles
QQmlJSScope::Ptr m_savedBindingOuterScope
QHash< QQmlJS::SourceLocation, QQmlJSMetaSignalHandler > m_signalHandlers
const QQmlJSImporter * importer() const
QHash< QV4::CompiledData::Location, QQmlJSScope::ConstPtr > m_scopesByIrLocation
QList< UnfinishedBinding > m_bindings
QHash< QQmlJSScope::Ptr, QVector< QQmlJSScope::Ptr > > m_pendingDefaultProperties
QQmlJSScope::Ptr result() const
QQmlJSScope::RootDocumentNameType InlineComponentOrDocumentRootName
QList< QQmlJSScope::ConstPtr > qmlTypes() const
QVector< QQmlJSScope::Ptr > m_objectDefinitionScopes
QVector< QQmlJSAnnotation > m_pendingMethodAnnotations
QQmlJSScopesById addressableScopes() const
QQmlJSScope::RootDocumentNameType RootDocumentNameType
QHash< QQmlJS::SourceLocation, QQmlJSMetaSignalHandler > signalHandlers() const
QVector< PendingMethodType > m_pendingMethodTypes
QHash< FunctionOrExpressionIdentifier, int > m_innerFunctions
QSet< QQmlJSScope::ConstPtr > literalScopesToCheck() const
QVector< PendingPropertyObjectBinding > m_pendingPropertyObjectBindings
BindingExpressionParseResult
QSet< QQmlJS::SourceLocation > m_importLocations
QVector< RequiredProperty > m_requiredProperties
QVector< PendingPropertyType > m_pendingPropertyTypes
QVector< QQmlJSScope::Ptr > m_objectBindingScopes
QSet< QQmlJSScope::ConstPtr > m_literalScopesToCheck
bool rootScopeIsValid() const
bool isTypeResolved(const QQmlJSScope::ConstPtr &type, ErrorHandler handle)
QSet< QQmlJSScope::ConstPtr > m_unresolvedTypes
const QQmlJSScope::Ptr m_exportedRootScope
QQmlJSImporter::ImportedTypes m_rootScopeImports
QHash< QQmlJSScope::Ptr, QVector< WithVisibilityScope< QString > > > m_propertyBindings
QQmlJSScope::ConstPtr scopeById(const QString &id, const QQmlJSScope::ConstPtr ¤t)
QHash< QV4::CompiledData::Location, QQmlJSScope::ConstPtr > scopesBylocation() const
QQmlJSScopesById m_scopesById
QString InlineComponentNameType
std::monostate RootDocumentNameType
std::variant< InlineComponentNameType, RootDocumentNameType > InlineComponentOrDocumentRootName
A Hashable type to differentiate document roots from different inline components.
QQmlJS::SourceLocation sourceLocation() const
bool preVisit(Node *) override
void postVisit(Node *) override
\macro QT_RESTRICTED_CAST_FROM_ASCII
Combined button and popup list for selecting options.
QList< QString > QStringList
Constructs a string list that contains the given string, str.
constexpr QtPrivate::QHashMultiReturnType< T... > qHashMulti(size_t seed, const T &... args) noexcept(std::conjunction_v< QtPrivate::QNothrowHashable< T >... >)
GLuint64 GLenum void * handle
GLint GLint GLint GLint GLint x
[0]
GLenum GLenum GLsizei count
GLsizei const GLchar *const * path
static Q_CONSTINIT QBasicAtomicInteger< unsigned > seed
friend bool operator==(const FunctionOrExpressionIdentifier &x, const FunctionOrExpressionIdentifier &y)
friend bool operator!=(const FunctionOrExpressionIdentifier &x, const FunctionOrExpressionIdentifier &y)
friend size_t qHash(const FunctionOrExpressionIdentifier &x, size_t seed=0)
QQmlJSScope::ConstPtr scope
QQmlJS::SourceLocation location
QQmlJS::SourceLocation location
QQmlJSScope::Ptr childScope
QQmlJS::SourceLocation location
QQmlJS::SourceLocation location
std::function< QQmlJSMetaPropertyBinding()> create
Utility wrapper that adds visibility scope to the data.
QQmlJSScope::Ptr visibilityScope
QQmlJS::SourceLocation dataLocation