From 53be7ebc2bd18fe3ff34561d6a0563318ca4c711 Mon Sep 17 00:00:00 2001 From: David Mitchell Date: Mon, 12 Sep 2011 14:32:11 +0100 Subject: make recent re_eval changes compile under -Dmad Note that this doesn't mean that MAD output is correct; I haven't tested that. In particular, I have no idea when and how CURMAD() is supposed to be used. --- toke.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/toke.c b/toke.c index eda9103f37..e1edfd0239 100644 --- a/toke.c +++ b/toke.c @@ -4630,6 +4630,8 @@ Perl_yylex(pTHX) PL_bufptr += 2; if (*PL_bufptr != '{') PL_bufptr++; + start_force(PL_curforce); + /* XXX probably need a CURMAD(something) here */ PL_expect = XTERMBLOCK; force_next(DO); } @@ -4685,7 +4687,9 @@ Perl_yylex(pTHX) PL_bufptr++; /* having compiled a (?{..}) expression, return the original * text too, as a const */ - PL_nextval[PL_nexttoke].opval = + start_force(PL_curforce); + /* XXX probably need a CURMAD(something) here */ + NEXTVAL_NEXTTOKE.opval = (OP*)newSVOP(OP_CONST, 0, newSVpvn(PL_sublex_info.re_eval_start, PL_bufptr - PL_sublex_info.re_eval_start)); -- cgit v1.2.1