perlmeditation
QM
This is something between a SOPW and a Meditation. I'm not really asking a question, just grousing...
<p>
I suspect every language has its idiosyncratic compiler error messages. I know Perl is not immune. Consider:
<code>
C:\>perl -c ag2gen.pl
"my" variable $i masks earlier declaration in same statement at ag2gen.pl line 1391.
"my" variable @test_order masks earlier declaration in same scope at ag2gen.pl line 1391.
"my" variable @test_order masks earlier declaration in same statement at ag2gen.pl line 1393.
"my" variable $i masks earlier declaration in same statement at ag2gen.pl line 1393.
"my" variable @test_order masks earlier declaration in same statement at ag2gen.pl line 1393.
"my" variable $j masks earlier declaration in same statement at ag2gen.pl line 1393.
"my" variable %test_order masks earlier declaration in same scope at ag2gen.pl line 1394.
"my" variable @test_order masks earlier declaration in same statement at ag2gen.pl line 1394.
"my" variable $i masks earlier declaration in same statement at ag2gen.pl line 1394.
"my" variable @test_order masks earlier declaration in same statement at ag2gen.pl line 1394.
"my" variable $j masks earlier declaration in same statement at ag2gen.pl line 1394.
syntax error at ag2gen.pl line 1389, near "2]"
ag2gen.pl had compilation errors.
</code>
Here are the offending lines:
<code>
1389: for my $i (0..@test_order-2])
1390: {
1391: for my $j ($i+1..@test_order-1)
1392: {
1393: unless ( ( $test_order[$i] eq $test_order[$j] )
1394: or exists($test_order{"$test_order[$i]\t$test_order[$j]"} ) )
</code>
<code>for my $i</code> doesn't mask anything. In fact, it doesn't compile (at least, not completely).
<div class="pmsig"><div class="pmsig-294463">
<p>-QM<br />
--<br />
Quantum Mechanics: The dreams stuff is made of
</div></div>