Perl Monk, Perl Meditation | |
PerlMonks |
Do the Splice Docs on Length Need Tweak?by QM (Parson) |
on Apr 29, 2019 at 13:36 UTC ( [id://1233117]=perlquestion: print w/replies, xml ) | Need Help?? |
QM has asked for the wisdom of the Perl Monks concerning the following question:
I recently looked up something on splice. Specifically, I wanted to insert something in an array, but not delete anything.
While it's implicit that a length of zero should not remove anything, and only insert the given list, it's not explicit. Should it be? Specifically, should the documentation include a line like so: If LENGTH is zero, nothing is removed. That would have reduced my time reading the doc, or needing to TIAS. Or maybe I've misread something in my haste, and it's there, plain as day? -QM
Back to
Seekers of Perl Wisdom
|
|