Commit 0fdb3beb authored by Roberto Raggi's avatar Roberto Raggi Committed by Thorbjørn Lindeijer
Browse files

Fixed crash when completing symbols without a valid context.

Task-number: QTCREATORBUG-534
Reviewed-by: default avatarThorbjørn Lindeijer <>
parent 738a950b
......@@ -352,8 +352,10 @@ QList<Scope *> LookupContext::visibleScopes(const QPair<FullySpecifiedType, Symb
QList<Scope *> LookupContext::visibleScopes(Symbol *symbol) const
QList<Scope *> scopes;
if (symbol) {
for (Scope *scope = symbol->scope(); scope; scope = scope->enclosingScope())
scopes += visibleScopes();
scopes = expand(scopes);
return scopes;
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