laziness, impatience, and hubris | |
PerlMonks |
Re^2: Opinion: where Perl5 wasn't attractive for meby sundialsvc4 (Abbot) |
on Nov 19, 2014 at 15:28 UTC ( [id://1107778]=note: print w/replies, xml ) | Need Help?? |
The keyword my was, at some time or another, merely someone’s syntactic choice ... to go along with our, perhaps. The key notion here is that identifiers are declared, to gaurd against typos that your eye will automatically read-over ... like the typo in this very sentence. If “all identifiers are declared,” the compiler can, at compile time, point-out that the variable-name guard is mis-spelled and that you really didn’t intend to have two variables. Nevertheless, the design (the philosophy?) of the Perl language is that you are given that sort of choice. If you choose to use these compiler-features (and you should ...) then those strictures will be enforced. But if you do not, they won’t. Odd as it may seem to you, even “wrong” as it may seem, this is a design choice. Many languages do carry “compile-time checking” to a much greater extreme than Perl does. They implement strong-typing, and rely much less on at-runtime decision making to carry out The Author’s Intent. Each approach, however, is neither right nor wrong. Perl will never “fundamentally change,” no matter how “–er” any particular fee-chur is thought to be, because that would break the most important thing: compatibility with the tens of millions of lines of mission-critical application code that has been written using it over the past decade(s). The same is true of every tool that has escaped the ivory tower (or, as with Perl, never was inside of one).
In Section
Meditations
|
|