aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/ADT
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-06-30 01:28:08 +0000
committerDan Gohman <gohman@apple.com>2009-06-30 01:28:08 +0000
commit29e708b3359f84090fbcaacc0d7c2c73f5159317 (patch)
tree31224654ef46fb6c5e3108fe5e6c920d38b1c64c /include/llvm/ADT
parenta7a87deadbedd003999f4da34959071aa7c0507b (diff)
downloadexternal_llvm-29e708b3359f84090fbcaacc0d7c2c73f5159317.zip
external_llvm-29e708b3359f84090fbcaacc0d7c2c73f5159317.tar.gz
external_llvm-29e708b3359f84090fbcaacc0d7c2c73f5159317.tar.bz2
Define an operator<< for APInt to be used with std::ostream.
This will allow it to be used in unittests that use gtest's EXPECT_EQ. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74494 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT')
-rw-r--r--include/llvm/ADT/APInt.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/llvm/ADT/APInt.h b/include/llvm/ADT/APInt.h
index 63bf4f6..56cd3cc 100644
--- a/include/llvm/ADT/APInt.h
+++ b/include/llvm/ADT/APInt.h
@@ -1426,6 +1426,8 @@ inline raw_ostream &operator<<(raw_ostream &OS, const APInt &I) {
return OS;
}
+std::ostream &operator<<(std::ostream &o, const APInt &I);
+
namespace APIntOps {
/// @brief Determine the smaller of two APInts considered to be signed.