Test2::Util::Ref(3)

πŸ“¦ version 1.302214, in opensuse-leap 16.0

πŸ’– NAME πŸ’–

okay so this is Test2::Util::Ref(3), bestie β€” a User Contributed Perl Documentation page all about tools for inspecting or manipulating references. slay.

✨ DESCRIPTION ✨

These little helpers are used by Test2::Tools to inspect, render, or manipulate references. no cap.

πŸŽ€ EXPORTS πŸŽ€

All exports are optional. You must specify subs to import β€” the module isn’t gonna just dump everything into your namespace uninvited, iykyk.

  • $type = rtype($ref) β€” a normalization between Scalar::Util::reftype() and ref(). It always returns a string. It returns 'REGEXP' for regex types. It returns '' for non-refs. Otherwise it returns what Scalar::Util::reftype() returns. periodt.
  • $addr_str = render_ref($ref) β€” always returns a string. For unblessed references this returns something like "SCALAR(0x...)". For blessed references it returns "My::Thing=SCALAR(0x...)". The only difference between this and $add_str = "$thing" is that it ignores any overloading to ensure it is always the ref address. πŸ’…

πŸ¦‹ SOURCE πŸ¦‹

The source code repository for Test2-Suite can be found at https://github.com/Test-More/test-more/.

🌸 MAINTAINERS 🌸

  • Chad Granum <exodist@cpan.org>

🌈 AUTHORS 🌈

  • Chad Granum <exodist@cpan.org>
  • Kent Fredric <kentnl@cpan.org>

Copyright Chad Granum <exodist@cpan.org>.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See http://dev.perl.org/licenses/


That’s the whole vibe, bestie. This page is from perl v5.42.0, dated 2025-07-28, and it’s the Test2::Util::Ref(3) manual. πŸ«ΆπŸ’–

πŸ“¦ where this page comes from