Perl::...wigils(3pm)
π
Perl::...wigils(3pm) β aka Perl::Tidy::Sweetened::Variable::Twigils
okay bestie, you found the manual for Perl::Tidy::Sweetened::Variable::Twigils, and honestly? it's giving niche-but-iconic. this is a Perl::Tidy::Sweetened filter plugin that handles twigils, and yes we're gonna walk through it together, no cap. π¦
β¨ NAME β¨
Perl::Tidy::Sweetened::Variable::Twigils</p> β a Perl::Tidy::Sweetened filter plugin that handles twigls. that's literally the whole job. she does one thing and she eats. π
πΈ VERSION πΈ
this one's rockin' version 1.20. periodt. π
π SYNOPSIS π
here's the vibe, copy it exactly:
our $plugins = Perl::Tidy::Sweetened::Pluggable->new();
$plugins->add_filter(
Perl::Tidy::Sweetened::Variable::Twigils->new(
twigil => '$!',
marker => 'TWG_BANG',
) );
so you build your pluggable thing, you add_filter, you hand it a new Perl::Tidy::Sweetened::Variable::Twigils, and you tell it your twigil and your marker. done. slay. β¨
π¦ DESCRIPTION π¦
okay so real talk: this is a Perl::Tidy::Sweetened filter, and what it does is enable the use of twigils as defined by the Twigils module. that's the whole plot. π«Ά
New accepts:
twigilβ liketwigil => '$!'
declares a new twigil. in this specific case, it's meant to be used as "$!variable". cute, right?
markerβ likemarker => 'TWG_BANG'
provides a text marker β a lil flag π© β to mark the new keywords during "prefilter".
so here's the β¨magicβ¨: your source code gets filtered prior to formatting by Perl::Tidy, such that this:
$!class_attribute
gets turned into this:
$__TWG_BANK_1
...and then, in the "postfilter", it gets turned back into the original twigiled variable. it's giving transform-and-restore, main character energy, iykyk. π«
lowkey obsessed with a filter that goes out and comes back like nothing happened. iconic behavior fr fr.
π AUTHOR π
Mark Grimes <mgrimes@cpan.org> β the author. we stan. π«Ά
π SOURCE π
the source repository lives at <https://github.com/mvgrimes/Perl-Tidy-Sweetened> β go peek, bestie, it's right there. β¨
π BUGS π
please report any bugs or feature requests on the bugtracker website <https://github.com/mvgrimes/Perl-Tidy-Sweetened/issues>. no gatekeeping, we wanna know. π
and when you do submit a bug or a request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature. that's the whole ask. a lil repro goes a long way, bestie. π
π COPYRIGHT AND LICENSE π
this software is copyright (c) 2023 by Mark Grimes <mgrimes@cpan.org>.
this is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
and that's the whole page!! πΈ run it on perl v5.36.0, dated 2023-06-18, and go forth and twigil responsibly. mwah π
β¨
π¦ where this page comes from
- debian trixie: perltidier 1.20-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: perltidier 1.20-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu questing: perltidier 1.20-1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms