This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
Re: automake and 'strict' Perl5
>>>>> "Russ" == Russ Allbery <rra@stanford.edu> writes:
Russ> va:~> perl
Russ> sub sum { my ($a, $b) = @_; return $a + $b }
Russ> @a = (1, 2);
Russ> print sum (@a, 3), "\n"
Russ> 3
Russ> Now this is clearly a bug. You're actually passing a sub that
Russ> takes two arguments an array and a number, and it's correctly
Russ> (according to how you wrote it) taking the first two and adding
Russ> them and ignoring the third. It might be nice for prototypes to
Russ> fix this.
This example convinces me we want to avoid prototypes for automake.
They don't seem to do what I'd like, which is always statically check
arguments, and never introduce weirdness.
Tom