[llvm-commits] [llvm-gcc-4.2] r79234 - /llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Duncan Sands
baldrick at free.fr
Mon Aug 17 04:56:36 PDT 2009
Author: baldrick
Date: Mon Aug 17 06:56:35 2009
New Revision: 79234
URL: http://llvm.org/viewvc/llvm-project?rev=79234&view=rev
Log:
Revert r78039: it breaks the Ada build due to c_language
being undefined. The use of c_dialect_cxx is only valid
when building a C-like language. It happens to work with
Fortran because an Apple local change to the Fortran
front-end makes it define c_language, causing Fortran to
be considered C! I think a different kind of solution
needs to be found.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Modified: llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp?rev=79234&r1=79233&r2=79234&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Mon Aug 17 06:56:35 2009
@@ -421,11 +421,7 @@
// allows C functions declared as "T foo() {}" to be treated like
// "T foo(void) {}" and allows us to handle functions with K&R-style
// definitions correctly.
- // Don't do this for c++. In c++ "T foo() {}" is not varargs and
- // if the user typed "T foo(...)", he probably wants a varargs
- // function. This also avoids a warning in instcombine. See
- // llvm.org/PR4678
- if (TYPE_ARG_TYPES(TREE_TYPE(FnDecl)) == 0 && !c_dialect_cxx()) {
+ if (TYPE_ARG_TYPES(TREE_TYPE(FnDecl)) == 0) {
FTy = TheTypeConverter->ConvertArgListToFnType(TREE_TYPE(FnDecl),
DECL_ARGUMENTS(FnDecl),
static_chain,
More information about the llvm-commits
mailing list