diff --git a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/cxx14/constexpr/FunctionTests.java b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/cxx14/constexpr/FunctionTests.java index 7a02be8d2b5..90bc538a0f4 100644 --- a/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/cxx14/constexpr/FunctionTests.java +++ b/core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/cxx14/constexpr/FunctionTests.java @@ -282,11 +282,10 @@ public class FunctionTests extends TestBase { assertEvaluationEquals(58); } - // //Empty header file - // constexpr int f() { // return ([]() constexpr -> int {return 58;})(); // } + // constexpr int x = f(); public void testLambdaExpression2_560483() throws Exception { assertEvaluationEquals(58); diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java index 05b9367d2f2..9b683b08a2e 100644 --- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java +++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/dom/cpp/PDOMCPPLinkage.java @@ -1270,8 +1270,8 @@ class PDOMCPPLinkage extends PDOMLinkage implements IIndexCPPBindingConstants { if (owner instanceof IFunction) { boolean isTemplateParameter = binding instanceof ICPPTemplateParameter; boolean ownerIsConstexprFunc = owner instanceof ICPPFunction && ((ICPPFunction) owner).isConstexpr(); - boolean isVariableOrTypedef = binding instanceof ICPPVariable || binding instanceof ITypedef; - if (!isTemplateParameter && !(ownerIsConstexprFunc && isVariableOrTypedef)) { + boolean isVariableOrType = binding instanceof ICPPVariable || binding instanceof IType; + if (!isTemplateParameter && !(ownerIsConstexprFunc && isVariableOrType)) { return null; } }