diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-05-31 05:01:47 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-05-31 05:01:47 +0000 |
commit | d64830355c411305652aeae96623a3ca530d6d38 (patch) | |
tree | 047b92b240d44e6d3f29d85db3af5f23cedd2b85 /op.c | |
parent | 5eb85357989417f39c9b142b6f053d886d09816b (diff) | |
download | perl-d64830355c411305652aeae96623a3ca530d6d38.tar.gz |
scalar() doesn't force scalar context when used in void context
(from Simon Cozens)
p4raw-id: //depot/perl@6171
Diffstat (limited to 'op.c')
-rw-r--r-- | op.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1165,7 +1165,6 @@ Perl_scalarvoid(pTHX_ OP *o) case OP_DBSTATE: case OP_ENTERTRY: case OP_ENTER: - case OP_SCALAR: if (!(o->op_flags & OPf_KIDS)) break; /* FALL THROUGH */ @@ -1184,6 +1183,8 @@ Perl_scalarvoid(pTHX_ OP *o) case OP_REQUIRE: /* all requires must return a boolean value */ o->op_flags &= ~OPf_WANT; + /* FALL THROUGH */ + case OP_SCALAR: return scalar(o); case OP_SPLIT: if ((kid = cLISTOPo->op_first) && kid->op_type == OP_PUSHRE) { |