diff options
Diffstat (limited to 'src/shared/cplusplus/CheckDeclarator.cpp')
-rw-r--r-- | src/shared/cplusplus/CheckDeclarator.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/shared/cplusplus/CheckDeclarator.cpp b/src/shared/cplusplus/CheckDeclarator.cpp index 84edbd0292..8fb80549e6 100644 --- a/src/shared/cplusplus/CheckDeclarator.cpp +++ b/src/shared/cplusplus/CheckDeclarator.cpp @@ -260,7 +260,9 @@ bool CheckDeclarator::visit(ObjCMethodPrototypeAST *ast) return false; } - FullySpecifiedType returnType = semantic()->check(ast->type_name, _scope); + FullySpecifiedType returnType; + if (ast->type_name && ast->type_name->type_id) + returnType = semantic()->check(ast->type_name->type_id, _scope); unsigned location = ast->selector->firstToken(); |