aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/llvm/Attributes.h2
-rw-r--r--include/llvm/Operator.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/include/llvm/Attributes.h b/include/llvm/Attributes.h
index 1296d67d52..580ae7339e 100644
--- a/include/llvm/Attributes.h
+++ b/include/llvm/Attributes.h
@@ -223,7 +223,7 @@ public:
/// paramHasAttr - Return true if the specified parameter index has the
/// specified attribute set.
bool paramHasAttr(unsigned Idx, Attributes Attr) const {
- return getAttributes(Idx) & Attr;
+ return static_cast<bool>(getAttributes(Idx) & Attr);
}
/// getParamAlignment - Return the alignment for the specified function
diff --git a/include/llvm/Operator.h b/include/llvm/Operator.h
index 60865aa8ad..d848417625 100644
--- a/include/llvm/Operator.h
+++ b/include/llvm/Operator.h
@@ -99,7 +99,7 @@ public:
/// hasNoSignedWrap - Test whether this operation is known to never
/// undergo signed overflow, aka the nsw property.
bool hasNoSignedWrap() const {
- return SubclassOptionalData & NoSignedWrap;
+ return static_cast<bool>(SubclassOptionalData & NoSignedWrap);
}
static inline bool classof(const OverflowingBinaryOperator *) { return true; }