PPIx::U...Language(3)

πŸ’– PPIx::Utils::Language β€” the Perl-vibes helper module πŸ’–

okay so bestie, welcome to PPIx::Utils::Language(3) β€” it's a Perl manual page, and honestly? it's giving "small module, big brain energy". it lives in the User Contributed Perl Documentation section of your man pages, and it's literally just a little toolbox of functions that deal with aspects of the Perl language itself. slay.


✨ NAME ✨

PPIx::Utils::Language β€” Utility functions for PPI related to the Perl language πŸ¦‹


✨ SYNOPSIS ✨

the whole vibe, in one line:

use PPIx::Utils::Language ':all';

that's it. that's the post. πŸ’…


✨ DESCRIPTION ✨

so this package is a component of PPIx::Utils, and its whole thing is containing functions related to aspects of the Perl language. no cap β€” that's the job description. it's the language-flavored corner of the PPIx::Utils universe. πŸŽ€


✨ FUNCTIONS ✨

good news bestie: all functions can be imported by name, or with the tag :all. pick your fighter. 🌈

🌸 precedence_of

my $precedence = precedence_of($element);

hand it a PPI::Token::Operator or just a plain string, and it hands you back the precedence of the operator, where 1 is the highest precedence. iconic hierarchy behaviour tbh.

⚠️ heads up: it returns undef if the precedence can't be determined β€” which is usually because it's not an operator at all. not every token gets to be an operator, and that's okay. πŸ’€

🌸 symbol_without_sigil

my $name = symbol_without_sigil($symbol);

this one returns the name of the specified symbol with any sigil at the front β€” i.e. the sigil gets yeeted. ✨

the parameter can be a vanilla Perl string or a PPI::Element. either one, no judgement. 🫢


✨ BUGS ✨

found a problem? report any issues on the public bugtracker. be a good citizen about it, bestie. πŸ›


✨ AUTHOR ✨

Dan Book <dbook@cpan.org> πŸ‘‘

and the code originally came from:

  • Perl::Critic::Utils by Jeffrey Ryan Thalhammer <jeff@imaginative-software.com>
  • Perl::Critic::Utils::Perl by Elliot Shank <perl@galumph.com>

legacy icons fr fr. 🌟


this software is copyright (c) 2005-2011 Imaginative Software Systems, 2007-2011 Elliot Shank, 2017 Dan Book.

and it's free software, babes: you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. periodt. πŸ’–


✨ SEE ALSO ✨

go touch grass in these other modules too:

  • Perl::Critic::Utils
  • Perl::Critic::Utils::Perl

iykyk. πŸ¦‹


and that's the whole page, bestie!! πŸŽ€ this lil masterpiece is brought to you by perl v5.42.0, dated 2025-08-05, and it's the PPIx::Utils::Language(3) manual page β€” go forth and check operator precedence responsibly. mwah πŸ’…βœ¨πŸ’œ

πŸ“¦ where this page comes from