Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathan Ridge2014-12-27 03:19:21 +0000
committerSergey Prigogin2014-12-27 23:14:22 +0000
commitcc7bf7b392af6f7cabdae7d7ec959cc7378fa72f (patch)
treef59b281eff59f72145c0a13dfd62b3e7c84793dc
parent787d0e16422cbfe473407b9209aeb2c8bf23e0ae (diff)
downloadorg.eclipse.cdt-cc7bf7b392af6f7cabdae7d7ec959cc7378fa72f.tar.gz
org.eclipse.cdt-cc7bf7b392af6f7cabdae7d7ec959cc7378fa72f.tar.xz
org.eclipse.cdt-cc7bf7b392af6f7cabdae7d7ec959cc7378fa72f.zip
Bug 456207 - Skip ICPPASTFunctionDeclarator.getNoexceptExpression() in
ASTComparer Change-Id: I298f52e9ad21643d8fe58283e0c30e95c12b92ad Signed-off-by: Nathan Ridge <zeratul976@hotmail.com> Reviewed-on: https://git.eclipse.org/r/38788 Tested-by: Hudson CI Reviewed-by: Sergey Prigogin <eclipse.sprigogin@gmail.com> Tested-by: Sergey Prigogin <eclipse.sprigogin@gmail.com>
-rw-r--r--core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ASTComparer.java7
-rw-r--r--core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java5
2 files changed, 11 insertions, 1 deletions
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 75e75d4f9d..c855b0120a 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 5471341e96..c9fa1e31a9 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();
+ }
}

Back to the top