diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPFunctionScope.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPFunctionScope.java index d5c7a7fe580..9c36a633c3f 100644 --- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPFunctionScope.java +++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/CPPFunctionScope.java @@ -87,7 +87,9 @@ public class CPPFunctionScope extends CPPScope implements ICPPFunctionScope { IASTName [] ns = qual.getNames(); if( ns.length > 1){ IBinding binding = ns[ ns.length - 2 ].resolveBinding(); - if( binding instanceof ICPPClassType ) + if (binding == null) + return null; + else if( binding instanceof ICPPClassType ) return ((ICPPClassType)binding).getCompositeScope(); else if( binding instanceof ICPPNamespace ) return ((ICPPNamespace)binding).getNamespaceScope(); diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPClassType.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPClassType.java index 6323da33b7c..da49d9b0608 100644 --- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPClassType.java +++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPClassType.java @@ -166,7 +166,7 @@ public class PDOMCPPClassType extends PDOMMemberOwner implements ICPPClassType, } public IScope getParent() throws DOMException { - throw new PDOMNotImplementedError(); + return null; } public IASTNode getPhysicalNode() throws DOMException {