in reply to A pair of "mathematical" attributes for arrays?
I have yet to encounter a case when would the uninitialized warning actually help. So I'd suggest using
use warnings; no warnings 'uninitialized';
it might be helpfull though to be able to specify the default value for the item in arrays and hashes though. In some specific cases. What would be necessary though to treat the stuff in the attribute as a block, not evaluate it to an expression. Consider this:
You wouldn't want the default value to be the same arrayref/object, right?my @row :default([]); # or my @other :default(new Foo::Bar());
The :nocirc could be handy.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: A pair of "mathematical" attributes for arrays?
by lodin (Hermit) on Sep 10, 2007 at 14:17 UTC |