fmt::presentation_type

The presentation type of a format specifier, encoding which of the mutually exclusive type letters (e.g. 'd', 'x', 'f', 's') was used. Enumerators for unrelated categories (integral/character, string/pointer, floating-point) intentionally share numeric values because at most one category applies to a given argument type.

Synopsis

Declared in <fmt/base.h>

enum class presentation_type : unsigned char;

Members

NameDescription
none No presentation type specified; the default for the argument type is used.
debug Debug presentation ('?').
string String presentation ('s') for strings and bools.
dec Decimal presentation ('d').
hex Hexadecimal presentation ('x' or 'X').
oct Octal presentation ('o').
bin Binary presentation ('b' or 'B').
chr Character presentation ('c').
pointer Pointer presentation ('p').
exp Exponential (scientific) presentation ('e' or 'E').
fixed Fixed-point presentation ('f' or 'F').
general General presentation ('g' or 'G'), choosing between fixed and exponential based on the value and precision.
hexfloat Hexadecimal floating-point presentation ('a' or 'A').