[cfe-dev] gcc compatibility: error: number of arguments doesn't match prototype

Eli Friedman eli.friedman at gmail.com
Thu Mar 29 18:21:35 PDT 2012


On Thu, Mar 29, 2012 at 5:21 PM, Afriza N. Arief <afriza.na at gmail.com> wrote:
> On Fri, Mar 30, 2012 at 5:55 AM, Eli Friedman <eli.friedman at gmail.com> wrote:
>>
>> On Sat, Mar 17, 2012 at 4:19 AM, Afriza N. Arief <afriza.na at gmail.com> wrote:
>> > void taskmain(int argc, char* argv[]);
>> >
>> > void taskmain() {
>> >   printf("libtask");
>> > }
>> >
>> > Hello,
>> >
>> > for the above code, gcc reports error and clang -std=gnu89 keeps quiet.
>> >
>> > is this intentional?
>>
>> Not intentional... we really ought to be at least printing a warning
>> here.  Please file at http://llvm.org/bugs/ .
>
> Thank you, filed at http://llvm.org/bugs/show_bug.cgi?id=12414
>
> Any pointers roughly where in the code this can fixed?

Try Sema::MergeFunctionDecl in SemaDecl.cpp .

-Eli




More information about the cfe-dev mailing list