in reply to eval order of args to a sub
Evaluation order of arguments to a subroutine? One in a module, an intrinsic, or what?
Perl passes arguments to a subroutine as a list (see perlsub); the order in which the arguments are processed is dependent on how the subroutine is written. So, unless you've got access to the routine's source (or the routine is properly documented), I would not assume any particular order (although it's probably left to right, as mentioned in Re^7: finding number of contiguous letters by blazar).
Also, with my limited imagination, I can't conceive of a case where this matters and it's somewhere in the realm of what I've been taught as "good coding practice;" it reveals too much about the sub's internals.
punctuation correction
emc
Any New York City or Connecticut area jobs? I'm currently unemployed.
There are some enterprises in which a careful disorderliness is the true method.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: eval order of args to a sub
by dewey (Pilgrim) on May 30, 2007 at 19:36 UTC |