LLVM 20.0.0git
|
Implementation of format_provider<T> for integral arithmetic types. More...
#include "llvm/Support/FormatProviders.h"
Static Public Member Functions | |
static void | format (const T &V, llvm::raw_ostream &Stream, StringRef Style) |
Additional Inherited Members | |
Static Protected Member Functions inherited from llvm::support::detail::HelperFunctions | |
static std::optional< size_t > | parseNumericPrecision (StringRef Str) |
static std::optional< HexPrintStyle > | consumeHexStyle (StringRef &Str) |
static size_t | consumeNumHexDigits (StringRef &Str, HexPrintStyle Style, size_t Default) |
Implementation of format_provider<T> for integral arithmetic types.
The options string of an integral type has the grammar:
integer_options :: [style][digits] style :: digits :: <non-negative integer> 0-99
| x- | Hex no prefix, lower | 42 | 2a | Minimum # digits | | X- | Hex no prefix, upper | 42 | 2A | Minimum # digits | | x+ / x | Hex + prefix, lower | 42 | 0x2a | Minimum # digits | | X+ / X | Hex + prefix, upper | 42 | 0x2A | Minimum # digits | | N / n | Digit grouped number | 123456 | 123,456 | Ignored | | D / d | Integer | 100000 | 100000 | Ignored |
Definition at line 129 of file FormatProviders.h.
|
inlinestatic |
Definition at line 134 of file FormatProviders.h.
References assert(), llvm::Integer, llvm::Number, llvm::write_hex(), and llvm::write_integer().