boostorg / format

Boost.org format module
http://boost.org/libs/format
Boost Software License 1.0
25 stars 51 forks source link

Add support for boolean output using std::boolalpha, "%b" #31

Closed jeking3 closed 7 years ago

jeking3 commented 7 years ago

Proposal

Per the original idea found in Francis (Grizzly) Smit's Boost Trac issue, add support for conversion specifier 'b' that shall map to std::boolalpha. Given that std::uppercase only applies to numeric inputs, there will be no 'B' conversion specifier support; instead one can follow this documentation to customize the boolean string output:

http://en.cppreference.com/w/cpp/locale/numpunct/truefalsename