Skip to content

Commit

Permalink
Change references of HLL language to 'Raku'
Browse files Browse the repository at this point in the history
I'm not sure why there are *any* references to any implementation
of a HLL languages in NQP.  But it appears there are.  Change them
from 'perl6' to 'Raku', in preparation for a similar renaming action
for Rakudo.
  • Loading branch information
lizmat committed Jan 24, 2020
1 parent cb3c336 commit 41e9bd5
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/QRegex/Cursor.nqp
Expand Up @@ -89,7 +89,7 @@ role NQPMatchRole is export {
method PRECURSOR() { self."!cursor_init"(nqp::getattr_s($!shared, ParseShared, '$!target'), :p($!from)) }
method Str() { $!pos >= $!from ?? nqp::substr(nqp::getattr_s($!shared, ParseShared, '$!target'), $!from, nqp::sub_i(self.to, $!from)) !! '' }
method Num() { nqp::numify(self.Str()) }
method Int() { nqp::hllizefor(self.Str, 'perl6').Int }
method Int() { nqp::hllizefor(self.Str, 'Raku').Int }
method Bool() { $!pos >= $!from }
method chars() { $!pos >= $!from ?? nqp::sub_i(self.to, $!from) !! 0 }

Expand Down
2 changes: 1 addition & 1 deletion src/vm/js/Compiler.nqp
Expand Up @@ -291,7 +291,7 @@ class QAST::CompilerJS does DWIMYNameMangling does SerializeOnce {

return 0 if $var.scope eq 'local';

if $*HLL eq 'perl6' { # To make binding of signatures work
if $*HLL eq 'Raku' { # To make binding of signatures work
return 1;
}

Expand Down
6 changes: 3 additions & 3 deletions src/vm/js/nqp-runtime/core.js
Expand Up @@ -629,11 +629,11 @@ function fromJSToReturnValue(ctx, obj) {
exports.fromJSToReturnValue = fromJSToReturnValue;

function fromJSToArgument(obj) {
return fromJS(hll.getHLL('perl6'), obj, false, true);
return fromJS(hll.getHLL('Raku'), obj, false, true);
}

function fromJSToObject(ctx, obj) {
return fromJS(hll.getHLL('perl6'), obj, false, false);
return fromJS(hll.getHLL('Raku'), obj, false, false);
}

function fromJS(HLL, obj, isReturnValue, isArgument) {
Expand Down Expand Up @@ -1016,7 +1016,7 @@ const fakePerl6 = new FakePerl6();
op.getcomp = function(language) {
const compilerRegistry = globalContext.context.compilerRegistry;

if (language === 'perl6' && !compilerRegistry.has(language)) {
if (language === 'Raku' && !compilerRegistry.has(language)) {
return fakePerl6;
}

Expand Down
2 changes: 1 addition & 1 deletion src/vm/js/nqp-runtime/runtime.js
Expand Up @@ -481,7 +481,7 @@ exports.createIntArray = require('./BOOT.js').createIntArray;

const containerSpecs = require('./container-specs.js');
exports.extraRuntime = function(lang, path) {
if (lang != 'perl6') throw 'only loading extra runtime for perl 6 is supported';
if (lang != 'Raku') throw 'only loading extra runtime for Raku is supported';
const runtime = typeof path === 'string' ? require(path) : path.require(lang + '-runtime');
if (!runtime.loaded) {
runtime.loaded = true;
Expand Down
2 changes: 1 addition & 1 deletion src/vm/moar/HLL/Backend.nqp
Expand Up @@ -162,7 +162,7 @@ class HLL::Backend::MoarVM {
$conf-hash := nqp::hash('kind', $kind);
}

my @END := nqp::gethllsym('perl6', '@END_PHASERS');
my @END := nqp::gethllsym('Raku', '@END_PHASERS');
@END.push(-> { self.dump_profile_data($prof_end_sub(), $kind, $filename) })
if nqp::defined(@END);

Expand Down

0 comments on commit 41e9bd5

Please sign in to comment.