[cfe-commits] r72477 - /cfe/trunk/lib/Sema/SemaInit.cpp
Anders Carlsson
andersca at mac.com
Wed May 27 09:28:38 PDT 2009
Author: andersca
Date: Wed May 27 11:28:34 2009
New Revision: 72477
URL: http://llvm.org/viewvc/llvm-project?rev=72477&view=rev
Log:
Relax an assert to an if check.
Modified:
cfe/trunk/lib/Sema/SemaInit.cpp
Modified: cfe/trunk/lib/Sema/SemaInit.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaInit.cpp?rev=72477&r1=72476&r2=72477&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaInit.cpp (original)
+++ cfe/trunk/lib/Sema/SemaInit.cpp Wed May 27 11:28:34 2009
@@ -165,9 +165,9 @@
return true;
// FIXME: What do do if VD is null here?
- assert(VD && "Must have a var decl to construct into!");
- Init = CXXConstructExpr::Create(Context, VD, DeclType, Constructor,
- false, &Init, 1);
+ if (VD)
+ Init = CXXConstructExpr::Create(Context, VD, DeclType, Constructor,
+ false, &Init, 1);
return false;
}
More information about the cfe-commits
mailing list