@@ -1273,21 +1273,23 @@ class NQP::Actions is HLL::Actions {
1273
1273
: node($/ ) );
1274
1274
}
1275
1275
1276
- method quote :sym </ /> ($/ , $ key ? ) {
1277
- if $ key eq ' open' {
1278
- $ Regex ::P6Regex::Actions::REGEXNAME := pir::null__P();
1279
- @ BLOCK [0 ]. symbol(' $¢' , : scope(' lexical' ));
1280
- @ BLOCK [0 ]. symbol(' $/' , : scope(' lexical' ));
1281
- return 0 ;
1282
- }
1283
- my $ regex :=
1284
- Regex ::P6Regex::Actions::buildsub($ < p6regex > . ast, @ BLOCK . shift );
1285
- my $ past :=
1286
- PAST::Op. new (
1287
- : pasttype<callmethod >, : name<new >,
1288
- lexical_package_lookup([' Regex' , ' Regex' ], $/ ),
1289
- $ regex
1290
- );
1276
+ method quote :sym </ /> ($/ ) {
1277
+ my $ block := @ BLOCK . shift ;
1278
+ $ block [0 ]. push (PAST::Var. new (: name<self >, : scope<parameter >));
1279
+ $ block [0 ]. push (
1280
+ PAST::Var. new (: name<self >, : scope<register >, : isdecl(1 ),
1281
+ : viviself(PAST::Var. new ( : name<self >, : scope(' lexical_6model' ) ))));
1282
+ $ block [0 ]. push (PAST::Var. new (: name<$¢ >, : scope<lexical >, : isdecl(1 )));
1283
+ $ block [0 ]. push (PAST::Var. new (: name<$/ >, : scope<lexical >, : isdecl(1 )));
1284
+ $ block . symbol(' $¢' , : scope<lexical >);
1285
+ $ block . symbol(' $/' , : scope<lexical >);
1286
+
1287
+ my $ regex := QRegex::P6Regex::Actions::buildsub($ < p6regex > . ast, $ block );
1288
+ my $ past := PAST::Op. new (
1289
+ : pasttype<callmethod >, : name<new >,
1290
+ lexical_package_lookup([' NQPRegex' ], $/ ),
1291
+ $ regex );
1292
+
1291
1293
# In sink context, we don't need the Regex::Regex object.
1292
1294
$ past <sink > := $ regex ;
1293
1295
make $ past ;
0 commit comments