diff --git a/doc/api.rst b/doc/api.rst index d5c59037..d8e6ea65 100644 --- a/doc/api.rst +++ b/doc/api.rst @@ -309,7 +309,7 @@ The following user-defined literals are defined in ``fmt/format.h``. .. doxygenfunction:: operator""_format(const char *s, size_t n) -> detail::udl_formatter -.. doxygenfunction:: operator""_a(const char *s, size_t) -> detail::udl_arg +.. doxygenfunction:: operator""_a() -> detail::udl_arg Utilities --------- @@ -516,7 +516,7 @@ In order to make a type formattable via ``std::ostream`` you should provide a std::string s = fmt::format("The date is {}", date(2012, 12, 9)); // s == "The date is 2012-12-9" -.. doxygenfunction:: print(std::basic_ostream &os, const S &format_str, Args&&... args) +.. doxygenfunction:: print(std::basic_ostream &os, format_string fmt, T&&... args) .. _printf-api: diff --git a/include/fmt/ostream.h b/include/fmt/ostream.h index 30c04a2d..470a4df6 100644 --- a/include/fmt/ostream.h +++ b/include/fmt/ostream.h @@ -133,8 +133,8 @@ void vprint(std::basic_ostream& os, \endrst */ FMT_MODULE_EXPORT -template -void print(std::ostream& os, format_string fmt, Args&&... args) { +template +void print(std::ostream& os, format_string fmt, T&&... args) { vprint(os, fmt, fmt::make_format_args(args...)); }