Skip to content

Commit

Permalink
Update api.rst
Browse files Browse the repository at this point in the history
  • Loading branch information
vitaut authored Jan 13, 2024
1 parent 5d9d376 commit 1b55d10
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions doc/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ The {fmt} library API consists of the following parts:
All functions and types provided by the library reside in namespace ``fmt`` and
macros have prefix ``FMT_``.

.. _core-api:
.. _base-api:

Base API
========

``fmt/base.h`` defines the core API which provides main formatting functions
``fmt/base.h`` defines the base API which provides main formatting functions
for ``char``/UTF-8 with C++20 compile-time checks. It has minimal include
dependencies for better compile times. This header is only beneficial when
using {fmt} as a library (the default) and not in the header-only mode.
Expand Down Expand Up @@ -129,7 +129,7 @@ inheritance or composition. This way you can support standard format specifiers
without implementing them yourself. For example::

// color.h:
#include <fmt/core.h>
#include <fmt/base.h>

enum class color {red, green, blue};

Expand Down Expand Up @@ -273,7 +273,7 @@ binary footprint, for example (https://godbolt.org/z/vajfWEG4b):

.. code:: c++

#include <fmt/core.h>
#include <fmt/base.h>

void vlog(const char* file, int line, fmt::string_view format,
fmt::format_args args) {
Expand All @@ -293,7 +293,7 @@ binary footprint, for example (https://godbolt.org/z/vajfWEG4b):
Note that ``vlog`` is not parameterized on argument types which improves compile
times and reduces binary code size compared to a fully parameterized version.

.. doxygenfunction:: fmt::make_format_args(const Args&...)
.. doxygenfunction:: fmt::make_format_args(T&... args) -> detail::format_arg_store<Context, NUM_ARGS, 0, DESC>

.. doxygenclass:: fmt::format_arg_store
:members:
Expand Down Expand Up @@ -473,7 +473,7 @@ Using ``fmt::join``, you can separate tuple elements with a custom separator::
// Prints "1, a"
fmt::print("{}", fmt::join(t, ", "));

.. doxygenfunction:: fmt::join(Range &&range, string_view sep) -> join_view<detail::iterator_t<Range>, detail::sentinel_t<Range>>
.. doxygenfunction:: fmt::join(Range &&range, string_view sep) -> join_view<decltype(std::begin(range)), decltype(std::end(range))>
.. doxygenfunction:: fmt::join(It begin, Sentinel end, string_view sep) -> join_view<It, Sentinel>

.. _chrono-api:
Expand Down

0 comments on commit 1b55d10

Please sign in to comment.