Skip to content

Commit

Permalink
Fix JVM backend compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
vrurg committed Dec 1, 2023
1 parent fc2a5f6 commit 97e6a43
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/Perl6/Metamodel/GenericHOW.nqp
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,16 @@ class Perl6::Metamodel::GenericHOW
method instantiate_generic($obj, $type_environment) {
my $found := nqp::null();
my $name := self.name($obj);
my $repr := nqp::reprname($type_environment);
if $repr eq 'MVMContext' {
my $te-kind := $type_environment.HOW.name($type_environment);
#?if !jvm
if $te-kind eq 'BOOTContext' {
#?endif
#?if jvm
if $te-kind eq 'ContextRef' {
#?endif
$found := nqp::getlexrel($type_environment, $name);
}
elsif $repr eq 'VMHash' {
elsif $te-kind eq 'BOOTHash' {
$found := nqp::atkey($type_environment, $name);
}
elsif nqp::isconcrete($type_environment) && $type_environment.EXISTS-KEY($name) {
Expand Down

0 comments on commit 97e6a43

Please sign in to comment.