Migrate to mkdocs

This commit is contained in:
Victor Zverovich 2024-06-02 08:26:56 -07:00
parent 0714113974
commit 38ba3d3993
8 changed files with 18 additions and 22 deletions

View File

@ -426,9 +426,7 @@ parameter to avoid the expensive `<locale>` include.
`FMT_STRING` enables compile-time checks on older compilers. It requires
C++14 or later and is a no-op in C++11.
:: {.doxygendefine}
FMT_STRING
::
::: FMT_STRING
To force the use of legacy compile-time checks, define the preprocessor
variable `FMT_ENFORCE_COMPILE_STRING`. When set, functions accepting

View File

@ -223,8 +223,8 @@ class dynamic_format_arg_store
/**
\rst
Reserves space to store at least *new_cap* arguments including
*new_cap_named* named arguments.
Reserves space to store at least `new_cap` arguments including
`new_cap_named` named arguments.
\endrst
*/
void reserve(size_t new_cap, size_t new_cap_named) {

View File

@ -888,14 +888,14 @@ template <typename T> class buffer {
/// Clears this buffer.
void clear() { size_ = 0; }
// Tries resizing the buffer to contain *count* elements. If T is a POD type
// Tries resizing the buffer to contain `count` elements. If T is a POD type
// the new elements may not be initialized.
FMT_CONSTEXPR void try_resize(size_t count) {
try_reserve(count);
size_ = count <= capacity_ ? count : capacity_;
}
// Tries increasing the buffer capacity to *new_capacity*. It can increase the
// Tries increasing the buffer capacity to `new_capacity`. It can increase the
// capacity by a smaller amount than requested but guarantees there is space
// for at least one additional element either by increasing the capacity or by
// flushing the buffer if it is full.

View File

@ -914,11 +914,11 @@ class basic_memory_buffer : public detail::buffer<T> {
// Returns a copy of the allocator associated with this buffer.
auto get_allocator() const -> Allocator { return alloc_; }
/// Resizes the buffer to contain *count* elements. If T is a POD type new
/// Resizes the buffer to contain `count` elements. If T is a POD type new
/// elements may not be initialized.
FMT_CONSTEXPR20 void resize(size_t count) { this->try_resize(count); }
/// Increases the buffer capacity to *new_capacity*.
/// Increases the buffer capacity to `new_capacity`.
void reserve(size_t new_capacity) { this->try_reserve(new_capacity); }
using detail::buffer<T>::append;
@ -1810,7 +1810,7 @@ inline auto find_escape(const char* begin, const char* end)
}()
/**
* Constructs a compile-time format string from a string literal *s*.
* Constructs a compile-time format string from a string literal `s`.
*
* **Example**::
*
@ -3871,7 +3871,7 @@ FMT_API auto vsystem_error(int error_code, string_view format_str,
/**
* Constructs `std::system_error` with a message formatted with
* `fmt::format(fmt, args...)`.
* *error_code* is a system error code as given by `errno`.
* `error_code` is a system error code as given by `errno`.
*
* **Example**::
*
@ -3892,7 +3892,7 @@ auto system_error(int error_code, format_string<T...> fmt, T&&... args)
/**
\rst
Formats an error message for an error returned by an operating system or a
language runtime, for example a file opening error, and writes it to *out*.
language runtime, for example a file opening error, and writes it to `out`.
The format is the same as the one used by ``std::system_error(ec, message)``
where ``ec`` is ``std::error_code(error_code, std::generic_category()})``.
It is implementation-defined but normally looks like:
@ -3902,7 +3902,7 @@ auto system_error(int error_code, format_string<T...> fmt, T&&... args)
where *<message>* is the passed message and *<system-message>* is the system
message corresponding to the error code.
*error_code* is a system error code as given by ``errno``.
`error_code` is a system error code as given by ``errno``.
\endrst
*/
FMT_API void format_system_error(detail::buffer<char>& out, int error_code,
@ -4173,7 +4173,7 @@ template <typename T, typename Char = char> struct nested_formatter {
};
/**
* Converts *value* to ``std::string`` using the default format for type *T*.
* Converts `value` to `std::string` using the default format for type `T`.
*
* **Example**::
*

View File

@ -146,8 +146,8 @@ FMT_API std::system_error vwindows_error(int error_code, string_view format_str,
where *<message>* is the formatted message and *<system-message>* is the
system message corresponding to the error code.
*error_code* is a Windows error code as given by ``GetLastError``.
If *error_code* is not a valid error code such as -1, the system message
`error_code` is a Windows error code as given by ``GetLastError``.
If `error_code` is not a valid error code such as -1, the system message
will look like "error -1".
**Example**::
@ -437,7 +437,7 @@ class FMT_API ostream {
/**
\rst
Opens a file for writing. Supported parameters passed in *params*:
Opens a file for writing. Supported parameters passed in `params`:
* ``<integer>``: Flags passed to `open
<https://pubs.opengroup.org/onlinepubs/007904875/functions/open.html>`_

View File

@ -173,7 +173,7 @@ void vprint(std::basic_ostream<Char>& os,
/**
\rst
Prints formatted data to the stream *os*.
Prints formatted data to the stream `os`.
**Example**::

View File

@ -626,7 +626,7 @@ inline auto vfprintf(std::FILE* f, basic_string_view<Char> fmt,
/**
\rst
Prints formatted data to the file *f*.
Prints formatted data to the file `f`.
**Example**::

View File

@ -313,9 +313,7 @@ FMT_DEPRECATED void print(const text_style& ts, wformat_string<T...> fmt,
return print(stdout, ts, fmt, args...);
}
/**
Converts *value* to ``std::wstring`` using the default format for type *T*.
*/
/// Converts `value` to `std::wstring` using the default format for type `T`.
template <typename T> inline auto to_wstring(const T& value) -> std::wstring {
return format(FMT_STRING(L"{}"), value);
}