Commit 1bdae081 authored by Kai Koehne's avatar Kai Koehne
Browse files

Fix crash when loading file with attached properties

The metatype system doesn't know about attached properties,
and asserted when trying to call isListProperty().

Let's just assume that for such properties, "a : b" actually
means a is not of type QList.

Reviewed-by: Erik Verbruggen
parent 66b87a17
......@@ -391,7 +391,8 @@ void TextToModelMerger::syncNode(ModelNode &modelNode,
} else {
if (isValidPropertyForNode(modelNode, astPropertyName)) {
AbstractProperty modelProperty =;
if (modelProperty.metaInfo().isListProperty()) {
if (modelProperty.metaInfo().isValid()
&& modelProperty.metaInfo().isListProperty()) {
syncArrayProperty(modelProperty, QList<QmlJS::AST::UiObjectMember*>() << member, context, differenceHandler);
} else {
syncNodeProperty(modelProperty, binding, context, differenceHandler);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment