[PATCH] D29481: [Support] Add FormatVariadic support for chrono types
Zachary Turner via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 3 13:49:53 PST 2017
zturner added inline comments.
================
Comment at: include/llvm/Support/Chrono.h:70
+/// | "ms-" | 1s | 1000 |
+/// | "ms-n" | 1s | 1,000 ms |
+/// | "" | 1.0s | 1.00 s |
----------------
Shouldn't the output here be `1,000`? The presence of `-` suggests that the unit should not be displayed.
================
Comment at: include/llvm/Support/Chrono.h:109
+
+ static std::pair<InternalRep, StringRef> consume_unit(StringRef &Style,
+ const Dur &D) {
----------------
`consumeUnit`?
================
Comment at: include/llvm/Support/Chrono.h:127
+
+ static bool consume_show_unit(StringRef &Style) {
+ if (Style.empty())
----------------
`consumeShowUnit`?
https://reviews.llvm.org/D29481
More information about the llvm-commits
mailing list