summaryrefslogtreecommitdiff
path: root/perly.y
diff options
context:
space:
mode:
authorBranislav ZahradnĂ­k <barney@cpan.org>2020-12-11 17:19:10 +0100
committerKarl Williamson <khw@cpan.org>2020-12-27 09:46:09 -0700
commita1ad62bfea2492db90c01a1b1dfe6612521d7c3a (patch)
tree8c98274e484d670a171e3ecb4072c53756cb872d /perly.y
parent3d9ccdfc9c042f91d022df1227f4b05ddeca831c (diff)
downloadperl-a1ad62bfea2492db90c01a1b1dfe6612521d7c3a.tar.gz
Distinguish C- and perly- literals - PERLY_QUESTION_MARK
Diffstat (limited to 'perly.y')
-rw-r--r--perly.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/perly.y b/perly.y
index b05536b23a..7f1158857e 100644
--- a/perly.y
+++ b/perly.y
@@ -102,7 +102,7 @@
%nonassoc LSTOP LSTOPSUB
%left PERLY_COMMA
%right <ival> ASSIGNOP
-%right <ival> '?' PERLY_COLON
+%right <ival> PERLY_QUESTION_MARK PERLY_COLON
%nonassoc DOTDOT
%left <ival> OROR DORDOR
%left <ival> ANDAND
@@ -1158,7 +1158,7 @@ term[product] : termbinop
| termunop
| anonymous
| termdo
- | term[condition] '?' term[then] PERLY_COLON term[else]
+ | term[condition] PERLY_QUESTION_MARK term[then] PERLY_COLON term[else]
{ $$ = newCONDOP(0, $condition, $then, $else); }
| REFGEN term[operand] /* \$x, \@y, \%z */
{ $$ = newUNOP(OP_REFGEN, 0, $operand); }