|
Ookii.CommandLine for C++
2.0.0
|
Allows selection between the C++20 <format> library and libfmt. More...


Go to the source code of this file.
Namespaces | |
| ookii | |
| Namespace containing the core Ookii.CommandLine.Cpp types. | |
| ookii::format | |
| Namespace containing helper functions for formatting. | |
Macros | |
| #define | OOKII_FMT_NS fmt:: |
| The namespace which contains the formatting library. More... | |
| #define | OOKII_USING_LIBFMT |
| Indicates libfmt is in use. More... | |
Functions | |
| template<typename... Args> | |
| std::string | ookii::format::ncformat (const std::locale &loc, std::string_view format, Args &&... args) |
| Helper to format using a non-const format string without needing to explicitly construct a format_args. More... | |
| template<typename... Args> | |
| std::wstring | ookii::format::ncformat (const std::locale &loc, std::wstring_view format, Args &&... args) |
| Helper to format using a non-const format wide string without needing to explicitly construct a wformat_args. More... | |
Allows selection between the C++20 <format> library and libfmt.
This file makes it possible for Ookii.CommandLine.Cpp to work with either the standard <format> header provided in C++20, or with libfmt on compilers that don't provide <format>.
To force the use of libfmt even if <format> is available, you can define OOKII_FORCE_LIBFMT.
In addition, this header provides several helper types and functions used for formatting strings.
| #define OOKII_FMT_NS fmt:: |
The namespace which contains the formatting library.
This evaluates to std:: if <format> is available, otherwise to fmt::.
| #define OOKII_USING_LIBFMT |
Indicates libfmt is in use.
This is only defined if <format> is not available or OOKII_FORCE_LIBFMT is used.