mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 14:42:11 +02:00
Fix for Bug 172429 - [Content Assist] NPE in CPPTemplateScope.getParent (patch by Bryan Wilkinson)
This commit is contained in:
parent
7cf4d73796
commit
7bf2c30f75
1 changed files with 1 additions and 1 deletions
|
@ -67,7 +67,7 @@ public class CPPTemplateScope extends CPPScope implements ICPPTemplateScope {
|
|||
public IScope getParent() {
|
||||
ICPPASTTemplateDeclaration templateDecl = (ICPPASTTemplateDeclaration) getPhysicalNode();
|
||||
IASTName name = CPPTemplates.getTemplateName( templateDecl );
|
||||
IASTNode p = name.getParent();
|
||||
IASTNode p = name != null ? name.getParent() : null;
|
||||
if( p instanceof ICPPASTQualifiedName ){
|
||||
ICPPASTQualifiedName qual = (ICPPASTQualifiedName) p;
|
||||
IASTName [] names = qual.getNames();
|
||||
|
|
Loading…
Add table
Reference in a new issue