std::experi...::is_abi_tag(3)

πŸ“¦ version 2024.07.05, in nixpkgs unstable, opensuse-leap 16.0

πŸ’– std::experi...::is_abi_tag(3) πŸ’–

okay so bestie, this page is from the C++ Standard Libary (their spelling, not mine, iykyk 😭) and the manual page name is std::experi...::is_abi_tag(3). we're talking about std::experimental::is_abi_tag, and it's literally the main character of this page. periodt. πŸ’…

✨ NAME ✨

  • std::experimental::is_abi_tag β€” std::experimental::is_abi_tag. yeah, it's giving self-titled debut album πŸ’….

🌸 Synopsis 🌸

Defined in header <experimental/simd>

template< class T >                    (parallelism TS v2)
struct is_abi_tag;

lowkey the whole vibe: if T is an ABI tag in the simd_abi namespace, then it provides the member constant value equal true. for any other type, value is false. no cap. ✨

🧩 Template parameters 🧩

  • T β€” a type to check. that's the whole parameter, bestie.

πŸŽ€ Helper variable template πŸŽ€

template< class T >
(parallelism TS v2)
inline constexpr bool is_abi_tag_v = is_abi_tag<T>::value;

yup, it's a helper variable template, and it's inline constexpr, slay. 🌟

πŸ‘‘ Inherited from std::integral_constant πŸ‘‘

this thing is inherited from std::integral_constant, so it gets all that inherited energy. here's the breakdown:

πŸ’œ Member constants πŸ’œ

  • value β€” true if T is an ABI tag type, false otherwise. [static] (public static member constant) ✨

🫢 Member functions 🫢

  • operator bool β€” converts the object to bool, returns value. (public member function)
  • operator() β€” returns value. (C++14) (public member function)

🌈 Member types 🌈

  • value_type β€” bool
  • type β€” std::integral_constant<bool, value>

πŸ”₯ Example πŸ”₯

// Run this code

#include <experimental/simd>
#include <iostream>

int main()
{
    namespace stdx = std::experimental;
    std::cout << std::boolalpha
              << stdx::is_abi_tag_v<stdx::simd_abi::scalar> << '\n'
              << stdx::is_abi_tag_v<int> << '\n';
}

πŸ“ Output πŸ“

true
false

πŸ¦‹ See also πŸ¦‹

  • is_simd_flag_type β€” checks if a type is a simd flag type. (parallelism TS v2) (class template) πŸ¦‹

🌸 that's the whole page, bestie! source: cppreference.com · version/date: 2024.06.10 · page: std::experi...::is_abi_tag(3) 🌸
πŸ“¦ where this page comes from