|
JH-Toolkit v1.4.1
An engineering-oriented C++20 toolkit with duck-typed concepts, static design, async coroutines, and semantic containers — header-only, RTTI-free, and concurrency-friendly.
|
Variables | |
| template<typename SeqType> | |
| constexpr bool | enable_borrowed_range< jh::ranges::range_adaptor< SeqType > > |
Legal specialization of std::ranges::enable_borrowed_range. | |
| template<typename R, typename F> | |
| constexpr bool | enable_borrowed_range< jh::ranges::vis_transform_view< R, F > > |
Legal specialization of std::ranges::enable_borrowed_range. | |
| template<typename... Views> | |
| constexpr bool | enable_borrowed_range< jh::ranges::zip_view< Views... > > |
Legal specialization of std::ranges::enable_borrowed_range. | |
|
inlineconstexpr |
Legal specialization of std::ranges::enable_borrowed_range.
This specialization is explicitly permitted by the C++ standard. User code may provide template specializations for certain customization points declared under the std::ranges namespace, including std::ranges::enable_borrowed_range, to indicate that a custom range type models the borrowed-range property.
Static analyzers such as Clang-Tidy may emit a warning: "Modification of 'std' namespace can result in undefined behavior". This warning is triggered because Clang-Tidy heuristically treats any declaration inside a user-written namespace std block as a modification of the standard namespace, without recognizing that nested namespaces like std::ranges define a separate, standards-sanctioned customization domain.
Concretely:
std::tuple_element<> are recognized by Clang-Tidy as explicitly allowed and thus do not trigger the warning. std::ranges::enable_borrowed_range<T>) are equally legal under the standard, but Clang-Tidy does not check the whitelist at that depth and therefore incorrectly flags them as potential UB. This is a false positive — the specialization is fully standard-compliant and does not constitute undefined behavior.
|
inlineconstexpr |
Legal specialization of std::ranges::enable_borrowed_range.
This specialization is explicitly permitted by the C++ standard. User code may provide template specializations for certain customization points declared under the std::ranges namespace, including std::ranges::enable_borrowed_range, to indicate that a custom range type models the borrowed-range property.
Static analyzers such as Clang-Tidy may emit a warning: "Modification of 'std' namespace can result in undefined behavior". This warning is triggered because Clang-Tidy heuristically treats any declaration inside a user-written namespace std block as a modification of the standard namespace, without recognizing that nested namespaces like std::ranges define a separate, standards-sanctioned customization domain.
Concretely:
std::tuple_element<> are recognized by Clang-Tidy as explicitly allowed and thus do not trigger the warning. std::ranges::enable_borrowed_range<T>) are equally legal under the standard, but Clang-Tidy does not check the whitelist at that depth and therefore incorrectly flags them as potential UB. This is a false positive — the specialization is fully standard-compliant and does not constitute undefined behavior.
|
inlineconstexpr |
Legal specialization of std::ranges::enable_borrowed_range.
This specialization is explicitly permitted by the C++ standard. User code may provide template specializations for certain customization points declared under the std::ranges namespace, including std::ranges::enable_borrowed_range, to indicate that a custom range type models the borrowed-range property.
Static analyzers such as Clang-Tidy may emit a warning: "Modification of 'std' namespace can result in undefined behavior". This warning is triggered because Clang-Tidy heuristically treats any declaration inside a user-written namespace std block as a modification of the standard namespace, without recognizing that nested namespaces like std::ranges define a separate, standards-sanctioned customization domain.
Concretely:
std::tuple_element<> are recognized by Clang-Tidy as explicitly allowed and thus do not trigger the warning. std::ranges::enable_borrowed_range<T>) are equally legal under the standard, but Clang-Tidy does not check the whitelist at that depth and therefore incorrectly flags them as potential UB. This is a false positive — the specialization is fully standard-compliant and does not constitute undefined behavior.