projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
27ce577
)
CodeGen: further simplify assertion
author
Saleem Abdulrasool
<compnerd@compnerd.org>
Tue, 25 Nov 2014 03:49:50 +0000
(
03:49
+0000)
committer
Saleem Abdulrasool
<compnerd@compnerd.org>
Tue, 25 Nov 2014 03:49:50 +0000
(
03:49
+0000)
Use more of algorithm to simplify the assertion. Pointed out by David Blakie!
llvm-svn: 222721
clang/lib/CodeGen/CGCall.cpp
patch
|
blob
|
history
diff --git
a/clang/lib/CodeGen/CGCall.cpp
b/clang/lib/CodeGen/CGCall.cpp
index
d012710
..
6db753f
100644
(file)
--- a/
clang/lib/CodeGen/CGCall.cpp
+++ b/
clang/lib/CodeGen/CGCall.cpp
@@
-446,10
+446,8
@@
CodeGenTypes::arrangeLLVMFunctionInfo(CanQualType resultType,
ArrayRef<CanQualType> argTypes,
FunctionType::ExtInfo info,
RequiredArgs required) {
-#ifndef NDEBUG
- for (const auto &AT : argTypes)
- assert(AT.isCanonicalAsParam());
-#endif
+ assert(std::all_of(argTypes.begin(), argTypes.end(),
+ std::mem_fun_ref(&CanQualType::isCanonicalAsParam)));
unsigned CC = ClangCallConvToLLVMCallConv(info.getCC());