STD::HAS_UNIQUE_OBJECT_REPRESENTATIONS(3cxx)

🌸 NAME 🌸

std::has_unique_object_representations< _Tp > β€” bestie, it's has_unique_object_representations, and it's exactly what it says on the tin πŸ’…

This lil guy lives in the 3cxx manual (that's the C++ library section of the man pages, iykyk) and it's the trait that tells you whether two objects that are bit-identical are also value-identical. Periodt. ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <type_traits>

It Inherits std::integral_constant< bool, __v >. So like, it's not doing anything wild, it's just an integral_constant wearing a cute little trait outfit. πŸŽ€

🌈 Public Types

  • typedef integral_constant< bool, __v > type β€” the base type it inherits from, the whole blueprint situation πŸ’–
  • typedef bool value_type β€” the value type, and it's literally just bool. No cap. πŸ“

πŸ”₯ Public Member Functions

  • constexpr operator value_type () const noexcept β€” converts into value_type (that's bool, babe), constexpr, and noexcept so it will never throw at you 🫢
  • constexpr value_type operator() () const noexcept β€” callable! you can just do the () thing and get the value out. constexpr, noexcept, flawless πŸ’…

πŸ‘‘ Static Public Attributes

  • static constexpr bool value β€” the actual answer, right there as a static member. This is the main character of the whole page honestly ⭐

πŸ’œ Detailed Description πŸ’œ

template<typename _Tp>
struct std::has_unique_object_representations< _Tp >

has_unique_object_representations β€” that's the vibe, that's the name, that's the whole brand ✨

Since: C++17 β€” so if you're stuck on an older standard, sorry bestie, this one's not for you 😭


🧚 Author 🧚

Generated automatically by Doxygen for libstdc++ from the source code.


Not me getting emotionally attached to a compile-time type trait... but here we are πŸ™ˆ

πŸ’– That's the whole page! Signing off with all my love: this one was generated automatically by Doxygen for libstdc++, pulled straight from the source code, and it hangs out in the 3cxx manual section β€” no cap, that's the origin story, and I am obsessed πŸŒˆπŸ’€πŸŽ€

πŸ“¦ where this page comes from