Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling

Re: App::Cmd::Command and abstract encoding

by tobyink (Abbot)
on Feb 28, 2013 at 09:25 UTC ( #1021028=note: print w/replies, xml ) Need Help??

in reply to App::Cmd::Command and abstract encoding

One would hope that...

use utf8;

... would be sufficient, as that's how you tell Perl that some code is in UTF-8. It doesn't look like App::Cmd::Command pays heed to this though (see the abstract method defined therein).

I'd argue that this is a bug.

Personally I'd just do:

use utf8; use constant abstract => q(go to the café);
package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name

Replies are listed 'Best First'.
Re^2: App::Cmd::Command and abstract encoding
by McA (Priest) on Feb 28, 2013 at 09:43 UTC

    Hi tobyink,

    thank you for the fast answer. Before checking whether someone answered here I had a look at the source code, too. So I had to smile reading your comment.

    I'm pretty sure it should be easy to react on a pattern

    while in status $inpod.

    It seems to be a little harder to parse for a use utf8;-like statement.

    What do you think about scanning for =encoding ?

    Best regards

    P.S.: I forgot something: I work with App::Cmd in combination with dzil and dzil generates the pod entries for me.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1021028]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (10)
As of 2018-06-19 18:17 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (114 votes). Check out past polls.