[cfe-dev] FunctionDecls by typedef crash the C++ front-end
clattner at apple.com
Fri Oct 24 11:00:23 PDT 2008
On Oct 24, 2008, at 7:43 AM, Doug Gregor wrote:
>> In general I think there should be some convention, whether they are
>> produced or not should be the same for both front-ends. Producing
>> them for
>> C++ and not for C is more confusing.
> I think Argiris is voicing an important principle here: regardless of
> what dialect we're parsing, we should produce ASTs of the same form.
> Having the ParmVarDecls or not shouldn't be a C-vs-C++ decision, but
> there could be a function-definition-vs-non-function-definition
> decision. Sometimes the same syntax has different interpretations in
> different dialects---"void f();" in C vs. C++, for example---but the
> notion of a function "f" with no prototype or of a function f" that
> accepts no arguments and has a void return type is always the same in
> the AST.
I agree completely,
More information about the cfe-dev