projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
15991bf
)
Remove some redundancy.
author
Reid Spencer
<rspencer@reidspencer.com>
Tue, 27 Feb 2007 23:27:26 +0000
(23:27 +0000)
committer
Reid Spencer
<rspencer@reidspencer.com>
Tue, 27 Feb 2007 23:27:26 +0000
(23:27 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34702
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/VMCore/Constants.cpp
patch
|
blob
|
history
diff --git
a/lib/VMCore/Constants.cpp
b/lib/VMCore/Constants.cpp
index 0c5079643310971fe8ce03b481f82816c9215ce2..37e0abec988767c5d33bd6804d09c482752e7738 100644
(file)
--- a/
lib/VMCore/Constants.cpp
+++ b/
lib/VMCore/Constants.cpp
@@
-115,10
+115,7
@@
Constant *Constant::getNullValue(const Type *Ty) {
// Static constructor to create an integral constant with all bits set
ConstantInt *ConstantInt::getAllOnesValue(const Type *Ty) {
if (const IntegerType* ITy = dyn_cast<IntegerType>(Ty))
- if (ITy->getBitWidth() == 1)
- return ConstantInt::getTrue();
- else
- return ConstantInt::get(Ty, APInt::getAllOnesValue(ITy->getBitWidth()));
+ return ConstantInt::get(Ty, APInt::getAllOnesValue(ITy->getBitWidth()));
return 0;
}