Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 100936

Summary: [Parser] declSpec of Parameter of type function parsed incorrectly
Product: [Tools] CDT Reporter: Andrew Niefer <aniefer>
Component: cdt-parserAssignee: Markus Schorn <mschorn.eclipse>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3    
Version: 3.0   
Target Milestone: Future   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Andrew Niefer CLA 2005-06-20 14:57:54 EDT
typedef int t;
t f( t (t) );
     ^  ^2

This should be parsed as a function with a parameter which is a function
returning  t and taking 1 parameter type t.
We are currently almost right, the t that is marked should be the decl Spec,
however it is currently being parsed as the name of the parameter's function
declarator.  So currently, the parameter is named t and returning unspecified
instead of having no name and returning t.

The result is a problem on the 2nd mark due to a wrong type.  see
AST2CSpecFailingTest.test6_7_7s6().
Comment 1 Doug Schaefer CLA 2007-08-21 10:59:51 EDT
Future means you commit to fix it in the Future. Inboxes can't make committments. Moving to '--'.
Comment 2 Markus Schorn CLA 2008-06-03 11:23:12 EDT

*** This bug has been marked as a duplicate of bug 84242 ***