diff options
author | Gisle Aas <gisle@aas.no> | 2006-01-27 06:46:00 -0800 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-11-02 11:14:42 +0000 |
commit | cfc4a7da389202132834a0ef4ed2d46dd167c176 (patch) | |
tree | ae77ff805a66e190133b5ffc15238751f0c72ca1 /pp_hot.c | |
parent | f9c6ae86dc1f6723c795186e5f64836b2e6c2f01 (diff) | |
download | perl-cfc4a7da389202132834a0ef4ed2d46dd167c176.tar.gz |
Re: $, and say
Message-ID: <lrek2t1e8n.fsf@caliper.activestate.com>
with tweaks so "say;" continues to default to $_
plus a regression test
p4raw-id: //depot/perl@29187
Diffstat (limited to 'pp_hot.c')
-rw-r--r-- | pp_hot.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -752,7 +752,11 @@ PP(pp_print) if (MARK <= SP) goto just_say_no; else { - if (PL_ors_sv && SvOK(PL_ors_sv)) + if (PL_op->op_type == OP_SAY) { + if (PerlIO_write(fp, "\n", 1) == 0 || PerlIO_error(fp)) + goto just_say_no; + } + else if (PL_ors_sv && SvOK(PL_ors_sv)) if (!do_print(PL_ors_sv, fp)) /* $\ */ goto just_say_no; |