Skip to content

Commit 21bfbb9

Browse files
committed
Merge branch 'getstrfromname'
2 parents ac431ce + 31b2b51 commit 21bfbb9

14 files changed

+13
-4
lines changed

src/HLL/Actions.nqp

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -203,11 +203,19 @@ class HLL::Actions {
203203
}
204204

205205
method charname($/) {
206-
my $codepoint := $<integer>
207-
?? $<integer>.made
206+
#?if !moar
207+
my $codepoint := ?? $<integer>.made
208208
!! nqp::codepointfromname(~$/);
209-
$/.CURSOR.panic("Unrecognized character name $/") if $codepoint < 0;
209+
$/.CURSOR.panic("Unrecognized character name $/") if $codepoint < 0;
210210
make nqp::chr($codepoint);
211+
#?endif
212+
#?if moar
213+
my $codepoint := $<integer>
214+
?? nqp::chr($<integer>.made)
215+
!! nqp::getstrfromname(~$/);
216+
$/.CURSOR.panic("Unrecognized character name $/") if $codepoint eq '';
217+
make $codepoint;
218+
#?endif
211219
}
212220

213221
method charnames($/) {

src/vm/moar/QAST/QASTOperationsMAST.nqp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2386,6 +2386,7 @@ QAST::MASTOperations.add_core_moarop_mapping('isge_n', 'ge_n');
23862386

23872387
QAST::MASTOperations.add_core_moarop_mapping('cmp_s', 'cmp_s');
23882388
QAST::MASTOperations.add_core_moarop_mapping('unicmp_s', 'unicmp_s');
2389+
QAST::MASTOperations.add_core_moarop_mapping('getstrfromname', 'getstrfromname');
23892390
QAST::MASTOperations.add_core_moarop_mapping('iseq_s', 'eq_s');
23902391
QAST::MASTOperations.add_core_moarop_mapping('isne_s', 'ne_s');
23912392
QAST::MASTOperations.add_core_moarop_mapping('islt_s', 'lt_s');

src/vm/moar/stage0/MASTNodes.moarvm

0 Bytes
Binary file not shown.

src/vm/moar/stage0/MASTOps.moarvm

528 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
320 Bytes
Binary file not shown.

src/vm/moar/stage0/NQPHLL.moarvm

19.6 KB
Binary file not shown.

src/vm/moar/stage0/NQPP6QRegex.moarvm

2.86 KB
Binary file not shown.

src/vm/moar/stage0/QAST.moarvm

-6.94 KB
Binary file not shown.

src/vm/moar/stage0/QASTNode.moarvm

48 Bytes
Binary file not shown.

src/vm/moar/stage0/QRegex.moarvm

120 Bytes
Binary file not shown.

src/vm/moar/stage0/nqp.moarvm

1.03 KB
Binary file not shown.

src/vm/moar/stage0/nqpmo.moarvm

8 Bytes
Binary file not shown.

tools/build/MOAR_REVISION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2016.12-100-gf9e14e9
1+
2016.12-102-gc23bb45c

0 commit comments

Comments
 (0)