diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2014-02-20 12:21:21 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-02 14:48:03 +0100 |
commit | 1c509a887a177939556514cd7cd389031d05117c (patch) | |
tree | 4c3694e329a1f6c7416a15924e5c96347ccde510 /src/qml/compiler/qqmltypecompiler.cpp | |
parent | 8a81380cca802e230011464c9f25c0c1604909d7 (diff) |
[new compiler] When resolving names of attached properties, don't report the error at import time
Instead report it later with a more specific error message. This is consistent with the old compiler.
Change-Id: Iba345b7ecc8a9ff474938f69118665eb0d965594
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/compiler/qqmltypecompiler.cpp')
-rw-r--r-- | src/qml/compiler/qqmltypecompiler.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/qml/compiler/qqmltypecompiler.cpp b/src/qml/compiler/qqmltypecompiler.cpp index abb2f3f5e2..71a7c71dc1 100644 --- a/src/qml/compiler/qqmltypecompiler.cpp +++ b/src/qml/compiler/qqmltypecompiler.cpp @@ -468,8 +468,7 @@ bool QQmlPropertyCacheCreator::buildMetaObjectRecursively(int objectIndex, int r } else if (instantiatingBinding && instantiatingBinding->isAttachedProperty()) { QQmlCompiledData::TypeReference *typeRef = resolvedTypes->value(instantiatingBinding->propertyNameIndex); Q_ASSERT(typeRef); - Q_ASSERT(typeRef->type); - const QMetaObject *attachedMo = typeRef->type->attachedPropertiesType(); + const QMetaObject *attachedMo = typeRef->type ? typeRef->type->attachedPropertiesType() : 0; if (!attachedMo) { recordError(instantiatingBinding->location, tr("Non-existent attached object")); return false; |