summaryrefslogtreecommitdiff
path: root/toke.c
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2007-06-05 06:25:39 -0700
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2007-06-07 14:05:11 +0000
commit02255c606d03ddedf1941776619d3260891f7b92 (patch)
treec6898a2c5b36a80c0fa3f258f7fc81bb18da6aa8 /toke.c
parent4ee50d44aab4daa2990af918a17df7200b6e468c (diff)
downloadperl-02255c606d03ddedf1941776619d3260891f7b92.tar.gz
Re: [perl #43082] "$_[0]->method" interpolation
Message-Id: <064E3238-D26D-446D-9B7E-0DB8CEFDE0AD@cpan.org> p4raw-id: //depot/perl@31351
Diffstat (limited to 'toke.c')
-rw-r--r--toke.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/toke.c b/toke.c
index a375a777a4..b2b6ba1f72 100644
--- a/toke.c
+++ b/toke.c
@@ -4390,7 +4390,9 @@ Perl_yylex(pTHX)
--PL_lex_brackets;
if (PL_lex_state == LEX_INTERPNORMAL) {
if (PL_lex_brackets == 0) {
- if (*s != '[' && *s != '{' && (*s != '-' || s[1] != '>'))
+ if (*s == '-' && s[1] == '>')
+ PL_lex_state = LEX_INTERPENDMAYBE;
+ else if (*s != '[' && *s != '{')
PL_lex_state = LEX_INTERPEND;
}
}