1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 19:42:54 +02:00

output foo(void) as appropriate

llvm-svn: 10232
This commit is contained in:
Chris Lattner 2003-11-26 00:09:17 +00:00
parent 422381c755
commit 67eb3c7f04

View File

@ -941,6 +941,8 @@ void CWriter::printFunctionSignature(const Function *F, bool Prototype) {
if (FT->isVarArg() && !FT->getParamTypes().empty()) {
if (FT->getParamTypes().size()) FunctionInnards << ", ";
FunctionInnards << "..."; // Output varargs portion of signature!
} else if (!FT->isVarArg() && FT->getParamTypes().empty()) {
FunctionInnards << "void"; // ret() -> ret(void) in C.
}
FunctionInnards << ")";
// Print out the return type and the entire signature for that matter