[Edinburgh-pm] syntax error weirdness

David Baird lists.riverside at gmail.com
Thu Aug 4 16:58:01 PDT 2005


dave at evesham$ perl -e 'map { $_,1 } "x"'
dave at evesham$ perl -e 'map { "$_" } "x"'
dave at evesham$ perl -e 'map { "$_",1 } "x"'
syntax error at -e line 1, near "} "x""
Execution of -e aborted due to compilation errors.
dave at evesham$ perl -v

This is perl, v5.8.6 built for i386-freebsd-64int

Anybody know why the third line shouldn't compile? Just seems weird.

d.


More information about the Edinburgh-pm mailing list