STD::EXPERIMENTAL::_HAS_ADDRESSOF(3cxx)

πŸ“¦
version 9.5.0 Β· 3 versions
, in ubuntu noble

🌸 NAME 🌸

std::experimental::_Has_addressof< _Tp > β€” it's the trait that sniffs out whether there's an overloaded unary operator& hanging around. bestie, it's giving detective energy πŸ”πŸ’…


✨ SYNOPSIS ✨

#include <optional>

Inherits std::__or_<... >::type.


πŸ¦‹ DETAILED DESCRIPTION πŸ¦‹

template<typename _Tp>
    struct std::experimental::_Has_addressof< _Tp >

okay so this is the trait that detects the presence of an overloaded unary operator&. no cap, that's literally its whole thing 🌈

Practically speaking β€” and this is the part where it gets cute β€” it detects that operator when it's called on a const-qualified lvalue. The vibe check example being declval<const _Tp&>().operator&(). so like, const lvalue specifically, not just any old object, iykyk πŸ’œ

Definition at line 162 of file optional. ⭐ (yes, the file is literally named optional, iconic)

πŸ‘‘ AUTHOR πŸ‘‘

Generated automatically by Doxygen for libstdc++ straight from the source code. not a human author, just a robot doing its thing and honestly? slay πŸ€–βœ¨


and that's the whole page, bestie πŸŽ€ this came to you from the libstdc++ girlies, in the 3cxx manual section β€” go forth and detect those operator& overloads, you absolute main character πŸ’–πŸ¦‹

πŸ“¦ where this page comes from