Community
Participate
Working Groups
For the following code: template <typename T, typename U> auto add(T t, U u) -> decltype(t + u) // ERRORS HERE { return t + u; } the parser gives errors for the symbols t and u in the decltype: - Symbol 'u' could not be resolved - Symbol 't' could not be resolved This is valid C++0x code.
Created attachment 186265 [details] testcase + fix
Fixed in 8.0 > 20110107.
*** cdt cvs genie on behalf of mschorn *** Bug 333256: Name resolution in trailing return type. [*] CPPVisitor.java 1.146 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt-core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/cpp/semantics/CPPVisitor.java?root=Tools_Project&r1=1.145&r2=1.146 [*] AST2CPPTests.java 1.378 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt-core/org.eclipse.cdt.core.tests/parser/org/eclipse/cdt/core/parser/tests/ast2/AST2CPPTests.java?root=Tools_Project&r1=1.377&r2=1.378