I guess choroba (POD) and haukex (OO) are right.
This little sketch does nothing, except that it compiles:
package Siberia::Indent { use Role::Tiny; requires qw(beer); sub back { ... } sub over { ... } 1; } package Siberia::Acme { use Class::Tiny qw(beer); # whatever you need use Role::Tiny::With; with qw(Siberia::Indent); 1; } #!/usr/bin/env perl use strict; use warnings; use Siberia::Acme; use Try::Tiny; use feature qw(say); my $indent = Siberia::Acme->new( { beer => 2 } ); # say $indent->beer; try { $indent->back; } catch { say qq($_); }; try { $indent->over; } catch { say qq($_); }; __END__
See also Class::Tiny and Role::Tiny.
Best regards, Karl
«The Crux of the Biscuit is the Apostrophe»
perl -MCrypt::CBC -E 'say Crypt::CBC->new(-key=>'kgb',-cipher=>"Blowfish")->decrypt_hex($ENV{KARL});'Help
In reply to Re: Simple indentation. Does it need improvement?
by karlgoethebier
in thread Simple indentation. Does it need improvement?
by siberia-man
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |