[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[MacPerl] Perl 5.1.5r4 bug



A minor problem with perl5.1.5r4. In lib:IO:File.pm, on line 159 we find:

eval ($^O eq 'MacOS') ? <<'END_MAC' : <<'END_NOMAC';

However, because of the placement of the parens, perl evaluates that as:

eval ($^O eq 'MacOS') ? <<'END_MAC' : <<'END_NOMAC';
eval (1) ? <<'END_MAC' : <<'END_NOMAC';
1 ? <<'END_MAC' : <<'END_NOMAC';

which results in the string up to END_MAC, but nothing's ever done with
it, so _protect is never defined and IO::File::open fails.

A simple change, to:

eval ($^O eq 'MacOS' ? <<'END_MAC' : <<'END_NOMAC');

sucks the string into the eval, so _protect is defined and things
work swimmingly.

Other than that, 5.1.5r4 looks good. It even seems a little snappier
than 5.1.3r2.

Brian

***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch