mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-28 06:27:16 +00:00
Fix spello
Add negate overload llvm-svn: 9709
This commit is contained in:
parent
a309338bd4
commit
97da28f949
@ -134,11 +134,15 @@ private:
|
||||
|
||||
// Unary operators...
|
||||
inline Constant *operator~(const Constant &V) {
|
||||
assert(V.getType()->isIntegral() && "Cannot invert non-intergral constant!");
|
||||
assert(V.getType()->isIntegral() && "Cannot invert non-integral constant!");
|
||||
return ConstRules::get(V, V)->op_xor(&V,
|
||||
ConstantInt::getAllOnesValue(V.getType()));
|
||||
}
|
||||
|
||||
inline Constant *operator-(const Constant &V) {
|
||||
return ConstRules::get(V, V)->sub(Constant::getNullValue(V.getType()), &V);
|
||||
}
|
||||
|
||||
// Standard binary operators...
|
||||
inline Constant *operator+(const Constant &V1, const Constant &V2) {
|
||||
assert(V1.getType() == V2.getType() && "Constant types must be identical!");
|
||||
|
Loading…
Reference in New Issue
Block a user