Author: rsmith
Date: Fri Jul 25 19:47:13 2014
New Revision: 213996
URL: http://llvm.org/viewvc/llvm-project?rev=213996&view=rev
Log:
Improve -UNDEBUG binary size. We don't need a different assert fail message for
each different enum value here.
Modified:
cfe/trunk/lib/AST/Expr.cpp
Modified: cfe/trunk/lib/AST/Expr.cpp
URL:
http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/Expr.cpp?rev=213996&r1=213995&r2=213996&view=diff
==============================================================================
--- cfe/trunk/lib/AST/Expr.cpp (original)
+++ cfe/trunk/lib/AST/Expr.cpp Fri Jul 25 19:47:13 2014
@@ -195,12 +195,12 @@ SourceLocation Expr::getExprLoc() const
case Stmt::NoStmtClass: llvm_unreachable("statement without class");
#define ABSTRACT_STMT(type)
#define STMT(type, base) \
- case Stmt::type##Class: llvm_unreachable(#type " is not an Expr"); break;
+ case Stmt::type##Class: break;
#define EXPR(type, base) \
case Stmt::type##Class: return getExprLocImpl<type>(this, &type::getExprLoc);
#include "clang/AST/StmtNodes.inc"
}
- llvm_unreachable("unknown statement kind");
+ llvm_unreachable("unknown expression kind");
}
//===----------------------------------------------------------------------===//
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits