Copyright Matus Chochlik. Distributed under the Boost Software License, Version 1.0. See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt
#include <iostream>
auto main() -> int {
using s = std::string;
using std::cout;
using std::endl;
cout << s(
format(
"prefix-${1}-suffix") %
"BLAH") << endl;
cout << s(
format(
"${2}${1}${4}${3}${1}") %
"foo" %
"bar" %
"baz" %
"qux")
<< endl;
return 0;
}
Common code is placed in this namespace.
Definition: eagine.hpp:21
static auto format(std::string &&fmt_str) noexcept -> format_string_and_list< 0 >
Function taking a format string, returning an object for variable specification.
Definition: str_format.hpp:118