1
0
Fork 0
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:
Markus Schorn 2012-04-26 11:55:34 +02:00
parent 755d3975a6
commit ff6444f9b8
2 changed files with 11 additions and 1 deletions

View file

@ -9600,4 +9600,13 @@ public class AST2CPPTests extends AST2BaseTest {
public void testParentScopeOfCatchHandler_376246() throws Exception {
parseAndCheckBindings();
}
// struct MyClass {
// struct MyException {};
// void doSomething() throw(MyException);
// };
// void MyClass::doSomething() throw (MyException) {}
public void testScopeOfExceptionSpecification_377457() throws Exception {
parseAndCheckBindings();
}
}

View file

@ -982,7 +982,8 @@ public class CPPVisitor extends ASTQueries {
node= node.getParent();
}
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());
if (result != null)
return result;