summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/Support/NativeFormatTests.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2016-11-11 23:57:40 +0000
committerZachary Turner <zturner@google.com>2016-11-11 23:57:40 +0000
commit11db2642fb54487ef18c18cc8555d7ff2f5e823b (patch)
tree0398b217a7902566a3b9309268b2290dd900fc5c /llvm/unittests/Support/NativeFormatTests.cpp
parentda6b5721b52a9f8d74dceec91e19c230af271fb6 (diff)
downloadbcm5719-llvm-11db2642fb54487ef18c18cc8555d7ff2f5e823b.tar.gz
bcm5719-llvm-11db2642fb54487ef18c18cc8555d7ff2f5e823b.zip
[Support] Introduce llvm::formatv() function.
This introduces a new type-safe general purpose formatting library. It provides compile-time type safety, does not require a format specifier (since the type is deduced), and provides mechanisms for extending the format capability to user defined types, and overriding the formatting behavior for existing types. This patch additionally adds documentation for the API to the LLVM programmer's manual. Mailing List Thread: http://lists.llvm.org/pipermail/llvm-dev/2016-October/105836.html Differential Revision: https://reviews.llvm.org/D25587 llvm-svn: 286682
Diffstat (limited to 'llvm/unittests/Support/NativeFormatTests.cpp')
-rw-r--r--llvm/unittests/Support/NativeFormatTests.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/unittests/Support/NativeFormatTests.cpp b/llvm/unittests/Support/NativeFormatTests.cpp
index 94508b7367d..52acb6a9933 100644
--- a/llvm/unittests/Support/NativeFormatTests.cpp
+++ b/llvm/unittests/Support/NativeFormatTests.cpp
@@ -21,7 +21,7 @@ namespace {
template <typename T> std::string format_number(T N, IntegerStyle Style) {
std::string S;
llvm::raw_string_ostream Str(S);
- write_integer(Str, N, Style);
+ write_integer(Str, N, 0, Style);
Str.flush();
return S;
}
OpenPOWER on IntegriCloud