hurricup has asked for the wisdom of the Perl Monks concerning the following question:
According to docs for strict subs:
This disables the poetry optimization, generating a compile-time error if you try to use a bareword identifier that's not a subroutine, unless it is a simple identifier (no colons) and that it appears in curly braces or on the left hand side of the => symbol.
But use Some::Thing -base;, for example, works and not looks like example in docs. Also, it may cause a surprise, when sub with name 'base' been defined before this use.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Why perl with strict allows to use -bareword?
by Anonymous Monk on Jun 27, 2017 at 20:14 UTC | |
by hurricup (Pilgrim) on Jun 28, 2017 at 05:19 UTC | |
|
Re: Why perl with strict allows to use -bareword?
by Anonymous Monk on Jun 27, 2017 at 20:26 UTC | |
by Anonymous Monk on Jun 27, 2017 at 20:40 UTC | |
by hurricup (Pilgrim) on Jun 28, 2017 at 05:18 UTC |