libstdc++: Fix errors in Doxygen markup

libstdc++-v3/ChangeLog:

	* doc/doxygen/doxygroups.cc: Define variable_templates group.
	* include/bits/binders.h: Fix @file name.
	* include/bits/formatfwd.h: Add missing @cond
	* include/bits/forward_list.h: Add closing backtick in comment.
	* include/bits/out_ptr.h (out_ptr, inout_ptr): Fix names in
	@param comments.
	* include/bits/regex_constants.h: Escape backtick in comment.
	* include/bits/stl_map.h: Add missing @{.
	* include/bits/stl_set.h: Likewise.
	* include/bits/stl_pair.h: Move declaration of complex into #if
	group where it's used. Fix nesting of @cond and @endcond in #if
	groups.
	* include/std/functional: Move @cond inside #if group.
	* include/std/type_traits: Likewise.
	* libsupc++/exception: Fix typo'd backtick.

Reviewed-by: Tomasz Kamiński <tkaminsk@redhat.com>
This commit is contained in:
Jonathan Wakely
2026-03-31 16:00:41 +01:00
committed by Jonathan Wakely
parent 210f884e00
commit 9b3957cd59
12 changed files with 37 additions and 16 deletions

View File

@@ -164,6 +164,21 @@ summarized in <a href="tables.html">tables</a>. */
* and condition variables.
*/
/**
* @defgroup variable_templates Variable Templates
* @ingroup metaprogramming
* @since C++17
*
* Each trait in `<type_traits>` that has a `value` static data member is
* also available as a variable template, using the same name with a `_v`
* suffix. For example, `std::is_integral_v<T>` is a `bool` constant with
* the same value as `std::is_integral<T>::value`.
*
* In some cases, using the variable template instead of the `::value` member
* avoids instantiating the class template for the trait. This gives the
* compiler less work to do and can make your code compile a little faster.
*/
/**
* @defgroup experimental Technical Specifications
*

View File

@@ -23,7 +23,7 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.
/** @file include/bits/binder.h
/** @file include/bits/binders.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{functional}
*/

View File

@@ -56,6 +56,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
// [format.formatter], formatter
template<typename _Tp, typename _CharT = char> struct formatter;
/// @cond undocumented
namespace __format
{
#ifdef _GLIBCXX_USE_WCHAR_T

View File

@@ -1461,7 +1461,7 @@ namespace __fwdlist
*
* This function will insert copies of the data in the range
* `[ __first, __last)` into the %forward_list after the
* location specified by `__pos.
* location specified by `__pos`.
*
* This operation is linear in the number of elements inserted and
* does not invalidate iterators and references.

View File

@@ -396,7 +396,7 @@ namespace __detail
/**
* @tparam _Pointer The type of pointer to convert to.
* @param __s The pointer that should take ownership of the result.
* @param __args... Arguments to use when resetting the smart pointer.
* @param __args Pack of arguments to use when resetting the smart pointer.
* @return A `std::out_ptr_t` referring to `__s`.
* @since C++23
* @headerfile <memory>
@@ -417,7 +417,7 @@ namespace __detail
/**
* @tparam _Pointer The type of pointer to convert to.
* @param __s The pointer that should take ownership of the result.
* @param __args... Arguments to use when resetting the smart pointer.
* @param __args Pack of arguments to use when resetting the smart pointer.
* @return A `std::inout_ptr_t` referring to `__s`.
* @since C++23
* @headerfile <memory>

View File

@@ -335,9 +335,9 @@ namespace regex_constants
* Format strings (from ECMA-262 [15.5.4.11]):
* @li $$ The dollar-sign itself ($)
* @li $& The matched substring.
* @li $` The portion of @a string that precedes the matched substring.
* @li $\` The portion of the string that precedes the matched substring.
* This would be match_results::prefix().
* @li $' The portion of @a string that follows the matched substring.
* @li $' The portion of the string that follows the matched substring.
* This would be match_results::suffix().
* @li $n The nth capture, where n is in [1,9] and $n is not followed by a
* decimal digit. If n <= match_results::size() and the nth capture

View File

@@ -1096,6 +1096,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CONTAINER
* is assigned from __obj.
*
* Insertion requires logarithmic time.
* @{
*/
template <typename _Obj>
pair<iterator, bool>

View File

@@ -101,9 +101,6 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<size_t...>
struct _Index_tuple;
template<typename _Tp>
class complex;
template<size_t _Int, class _Tp1, class _Tp2>
constexpr typename tuple_element<_Int, pair<_Tp1, _Tp2>>::type&
get(pair<_Tp1, _Tp2>& __in) noexcept;
@@ -153,6 +150,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
get(const array<_Tp, _Nm>&&) noexcept;
#if __glibcxx_tuple_like >= 202311 // >= C++26
template<typename _Tp>
class complex;
template<size_t _Int, typename _Tp>
constexpr _Tp&
get(complex<_Tp>&) noexcept;
@@ -233,8 +233,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
};
#endif // lib concepts
/// @endcond
#endif // C++11
/// @cond undocumented
#if __glibcxx_tuple_like // >= C++23
template<typename _Tp>
inline constexpr bool __is_tuple_v = false;

View File

@@ -585,6 +585,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CONTAINER
* to the first is returned.
*
* Insertion requires logarithmic time (if the hint is not taken).
* @{
*/
iterator
insert(const_iterator __position, const value_type& __x)

View File

@@ -148,9 +148,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
#endif // __cpp_lib_invoke_r
#if __cplusplus >= 201103L
/// @cond undocumented
#if __cplusplus >= 201103L
template<typename _MemFunPtr,
bool __is_mem_fn = is_member_function_pointer<_MemFunPtr>::value>
class _Mem_fn_base

View File

@@ -2484,15 +2484,15 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
const size_t aligned_union<_Len, _Types...>::alignment_value;
#pragma GCC diagnostic pop
/// @cond undocumented
// Decay trait for arrays and functions, used for perfect forwarding
// in make_pair, make_tuple, etc.
#if _GLIBCXX_USE_BUILTIN_TRAIT(__decay)
template<typename _Tp>
struct decay
{ using type = __decay(_Tp); };
#else
// Decay trait for arrays and functions, used for perfect forwarding
// in make_pair, make_tuple, etc.
/// @cond undocumented
template<typename _Up>
struct __decay_selector
: __conditional_t<is_const<const _Up>::value, // false for functions

View File

@@ -134,8 +134,8 @@ namespace std _GLIBCXX_VISIBILITY(default)
* stack unwinding [15.2]. end note]'
*
* 2: 'When `uncaught_exception()` is true, throwing an
* %exception can result in a call of 1terminate()`
* (15.5.1).'
* %exception can result in a call of `terminate()`
* (15.5.1).
*/
_GLIBCXX17_DEPRECATED_SUGGEST("std::uncaught_exceptions()")
bool uncaught_exception() _GLIBCXX_USE_NOEXCEPT __attribute__ ((__pure__));