diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-12-13 21:46:31 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-12-13 21:46:31 -0800 |
commit | 684d1b5f304d30ebb4202bc68e006be2562c64ed (patch) | |
tree | 55b13d612766b13273cb0be2c68b789e6c55a0bb | |
parent | 0830a9762cf236a516e7b44434e287082474e5c2 (diff) |
use signed by default, unless explicitly unsigned
-rw-r--r-- | lib/Target/CppBackend/CPPBackend.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Target/CppBackend/CPPBackend.cpp b/lib/Target/CppBackend/CPPBackend.cpp index b07f51eebb..df598ebd27 100644 --- a/lib/Target/CppBackend/CPPBackend.cpp +++ b/lib/Target/CppBackend/CPPBackend.cpp @@ -1512,7 +1512,7 @@ std::string CppWriter::getConstant(const Constant* CV, AsmCast sign) { //if (S.find('.') == S.npos) { TODO: do this when necessary, but it is necessary even for 0.0001 return S; } else if (const ConstantInt *CI = dyn_cast<ConstantInt>(CV)) { - return CI->getValue().toString(10, sign == ASM_SIGNED); + return CI->getValue().toString(10, sign != ASM_UNSIGNED); } else if (isa<UndefValue>(CV)) { return "0"; } else { |