mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-22 06:02:11 +02:00
Bug 377457: Name resolution for exception specification.
This commit is contained in:
parent
755d3975a6
commit
ff6444f9b8
2 changed files with 11 additions and 1 deletions
|
@ -9600,4 +9600,13 @@ public class AST2CPPTests extends AST2BaseTest {
|
||||||
public void testParentScopeOfCatchHandler_376246() throws Exception {
|
public void testParentScopeOfCatchHandler_376246() throws Exception {
|
||||||
parseAndCheckBindings();
|
parseAndCheckBindings();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// struct MyClass {
|
||||||
|
// struct MyException {};
|
||||||
|
// void doSomething() throw(MyException);
|
||||||
|
// };
|
||||||
|
// void MyClass::doSomething() throw (MyException) {}
|
||||||
|
public void testScopeOfExceptionSpecification_377457() throws Exception {
|
||||||
|
parseAndCheckBindings();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -982,7 +982,8 @@ public class CPPVisitor extends ASTQueries {
|
||||||
node= node.getParent();
|
node= node.getParent();
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
} else if (prop == ICPPASTFunctionDeclarator.TRAILING_RETURN_TYPE) {
|
} else if (prop == ICPPASTFunctionDeclarator.TRAILING_RETURN_TYPE ||
|
||||||
|
prop == ICPPASTFunctionDeclarator.EXCEPTION_TYPEID) {
|
||||||
IScope result = scopeViaFunctionDtor((ICPPASTFunctionDeclarator) node.getParent());
|
IScope result = scopeViaFunctionDtor((ICPPASTFunctionDeclarator) node.getParent());
|
||||||
if (result != null)
|
if (result != null)
|
||||||
return result;
|
return result;
|
||||||
|
|
Loading…
Add table
Reference in a new issue