in reply to Re^4: Hard syntax error or disambiguable parsing?
in thread Hard syntax error or disambiguable parsing?
The "variable" in a Perl for loop is aliased to each element that is being iterated over. It is effectively a symbolic place holder that is only valid within the scope of the loop body. However strict requires that variables are declared. Declaring the variable before the loop header makes it look like a normal variable - it ain't.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: Hard syntax error or disambiguable parsing?
by shmem (Chancellor) on Jan 29, 2009 at 10:15 UTC | |
|
Re^6: Hard syntax error or disambiguable parsing?
by ack (Deacon) on Jan 29, 2009 at 16:17 UTC | |
|
Re^6: Hard syntax error or disambiguable parsing?
by pobocks (Chaplain) on Jan 29, 2009 at 06:48 UTC | |
by GrandFather (Saint) on Jan 29, 2009 at 06:51 UTC |