[cfe-commits] r43449 - /cfe/trunk/CodeGen/CGExprAgg.cpp
Devang Patel
dpatel at apple.com
Mon Oct 29 09:56:27 PDT 2007
Author: dpatel
Date: Mon Oct 29 11:56:27 2007
New Revision: 43449
URL: http://llvm.org/viewvc/llvm-project?rev=43449&view=rev
Log:
Insetead of assert() just emit an error message for
an unimplemented work and continue.
Modified:
cfe/trunk/CodeGen/CGExprAgg.cpp
Modified: cfe/trunk/CodeGen/CGExprAgg.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/CodeGen/CGExprAgg.cpp?rev=43449&r1=43448&r2=43449&view=diff
==============================================================================
--- cfe/trunk/CodeGen/CGExprAgg.cpp (original)
+++ cfe/trunk/CodeGen/CGExprAgg.cpp Mon Oct 29 11:56:27 2007
@@ -185,8 +185,12 @@
unsigned NumInitElements = E->getNumInits();
- assert ( E->getType()->isArrayType()
- && "Only Array initializers are supported");
+ if (!E->getType()->isArrayType()) {
+ fprintf(stderr, "Unimplemented aggregate expr! ");
+ fprintf(stderr, "Only Array initializers are implemneted\n");
+ E->dump(CGF.getContext().SourceMgr);
+ return;
+ }
std::vector<llvm::Constant*> ArrayElts;
const llvm::PointerType *APType = cast<llvm::PointerType>(DestPtr->getType());
More information about the cfe-commits
mailing list