Skip to content
Snippets Groups Projects
Commit 499f7780 authored by Christian Kamm's avatar Christian Kamm
Browse files

Fix possible crash in QmlJS semantic checker.

parent cd53a562
No related branches found
No related tags found
No related merge requests found
...@@ -190,8 +190,11 @@ void Check::checkScopeObjectMember(const AST::UiQualifiedId *id) ...@@ -190,8 +190,11 @@ void Check::checkScopeObjectMember(const AST::UiQualifiedId *id)
return; return;
// attached properties // attached properties
if (! propertyName.isEmpty() && propertyName[0].isUpper()) if (! propertyName.isEmpty() && propertyName[0].isUpper()) {
scopeObject = _context.typeEnvironment(_doc.data()); scopeObject = _context.typeEnvironment(_doc.data());
if (! scopeObject)
return;
}
const Value *value = scopeObject->lookupMember(propertyName, &_context); const Value *value = scopeObject->lookupMember(propertyName, &_context);
if (_extraScope && !value) if (_extraScope && !value)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment