http://llvm.org/bugs/show_bug.cgi?id=6961
Summary: Incorrect prototype missing void in argument (easy to
fix).
Product: new-bugs
Version: 2.7
Platform: PC
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: new bugs
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Created an attachment (id=4753)
--> (http://llvm.org/bugs/attachment.cgi?id=4753)
Patch that makes the function prototype correct.
In include/llvm-c/Target.h function prototypes are generated with a macro.
The function prototypes look like
void fun();
which when compiling with gcc gives the warning
warning: function declaration isn’t a prototype
The reason for this is according to
http://stackoverflow.com/questions/42125/function-declaration-isnt-a-prototype
In C foo() and foo(void) are different functions. foo() accepts an infinite
number of arguments, while foo(void) accepts 0 arguments. In C++ they mean the
same thing. I suggest that you use void consistently when you mean no
arguments.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs