diff --git a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ASTComparer.java b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ASTComparer.java index 75e75d4f9dc..c855b0120a2 100644 --- a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ASTComparer.java +++ b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ASTComparer.java @@ -61,7 +61,12 @@ public class ASTComparer extends Assert { "isAssociatedWithLastName", "getNestingLevel", "getImplicitNames", - "isLValue" + "isLValue", + + // These methods can return a special constant value, such as + // ICPPASTFunctionDecalarator.NOEXCEPT_DEFAULT, which does not + // get cloned when the node is copied. + "getNoexceptExpression" )); public static void assertCopy(IASTNode node1, IASTNode node2) { diff --git a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java index 5471341e960..c9fa1e31a9f 100644 --- a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java +++ b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java @@ -11007,4 +11007,9 @@ public class AST2CPPTests extends AST2TestBase { // constexpr on a method *should not* make the method const assertSameType(waldo3.getType(), new CPPFunctionType(CommonTypes.int_, new IType[]{})); } + + // void waldo() noexcept; + public void testASTCopyForNoexceptDefault_bug456207() throws Exception { + parseAndCheckBindings(); + } }