Commit 0b4802c6 authored by Roberto Raggi's avatar Roberto Raggi
Browse files

Fixes: Possible crash in buildHelpId

parent 373a05af
......@@ -158,8 +158,10 @@ static QString buildHelpId(const FullySpecifiedType &type,
scope = e->scope();
} else if (const NamedType *t = type->asNamedType()) {
name = t->name();
} else if (const Declaration *d = symbol->asDeclaration()) {
if (d->scope() && d->scope()->owner()->isEnum()) {
} else if (symbol && symbol->isDeclaration()) {
const Declaration *d = symbol->asDeclaration();
if (d->scope() && d->scope()->isEnumScope()) {
name = d->name();
scope = d->scope();
}
......
Markdown is supported
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