PPIx::R...Operator(3)

✨ PPIx::Regexp::Token::Operator ✨

okay bestie, welcome to the PPIx::Regexp::Token::Operator page β€” it's part of the User Contributed Perl Documentation and it's literally all about operators. tiny class, big main character energy. let's go πŸ’…


🌸 NAME 🌸

PPIx::Regexp::Token::Operator β€” representing an operator, bestie. that's the whole job.


πŸŽ€ SYNOPSIS πŸŽ€

like, here's the vibe in code:

use PPIx::Regexp::Dumper;
PPIx::Regexp::Dumper->new( 'qr{foo|bar}smx' )
    ->print();

πŸ¦‹ INHERITANCE πŸ¦‹

"PPIx::Regexp::Token::Operator" is a PPIx::Regexp::Token. family tree, but make it simple 🫢

and "PPIx::Regexp::Token::Operator" has no descendants. it's the end of the line. the final girl. no cap.


πŸ’– DESCRIPTION πŸ’–

so this class represents an operator. that's it, that's the thesis ✨

here's the tea though β€” which operator depends on where it's chillin':

  • Inside a character class, it represents the negation ("^") and range ("-") operators.
  • Outside a character class, it represents the alternation ("|") operator.

periodt. πŸ’…


πŸ‘‘ METHODS πŸ‘‘

ngl this class provides no public methods beyond those provided by its superclass. it's lowkey just vibing off the inheritance. iconic behavior honestly.

🌈 operation 🌈

this method returns the name of the operation performed by the operator. and it's not just about the operator itself, bestie β€” it depends on the context too. it's giving situational awareness. 😌

πŸ“ In a bracketed character class

'-' => 'range',
'^' => 'inversion',

🧚 In an extended bracketed character class

'&' => 'intersection',
'+' => 'union',
'|' => 'union',
'-' => 'subtraction',
'^' => 'symmetric_difference',
'!' => 'complement',

⭐ Outside any sort of bracketed character class

'|' => 'alternation',

🫢 SUPPORT 🫢

support is by the author, so if something's acting up, please file bug reports at https://github.com/trwyant/perl-PPIx-Regexp/issues or slide into the author's electronic mail. don't suffer in silence bestie 😭


πŸ’œ AUTHOR πŸ’œ

Thomas R. Wyant, III β€” harryfmudd at comcast dot net


Copyright (C) 2009-2023, 2025-2026 by Thomas R. Wyant, III

This program is free software; you can redistribute it and/or modify it under the same terms as Perl 5.10.0. For more details, see the full text of the licenses in the directory LICENSES.

This program is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose.


okay that's the whole page bestie, no notes πŸ’–

and that's a wrap, angel πŸŽ€ β€” this was perl v5.42.2, dated 2026-06-15, and you just read the PPIx::Regexp::Token::Operator(3) page. slay, go parse some regexes βœ¨πŸ¦‹πŸ’…

πŸ“¦ where this page comes from