Skip to content

Instantly share code, notes, and snippets.

@lizmat
Created October 2, 2017 14:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lizmat/9c7c9697be9d1e727b34e550bdf91cda to your computer and use it in GitHub Desktop.
Save lizmat/9c7c9697be9d1e727b34e550bdf91cda to your computer and use it in GitHub Desktop.
possible fix for code ref / closure issue
diff --git a/src/Perl6/Metamodel/ClassHOW.nqp b/src/Perl6/Metamodel/ClassHOW.nqp
index 5c32f04..a9ed54c 100644
--- a/src/Perl6/Metamodel/ClassHOW.nqp
+++ b/src/Perl6/Metamodel/ClassHOW.nqp
@@ -147,7 +147,7 @@ class Perl6::Metamodel::ClassHOW
unless $was_composed {
# Create BUILDPLAN.
- my $BUILDALLPLAN := self.create_BUILDPLAN($obj);
+ self.create_BUILDPLAN($obj);
# Create BUILDALL method if we can (if we can't, the one from
# Mu will be used, which will iterate over the BUILDALLPLAN at
@@ -160,7 +160,7 @@ class Perl6::Metamodel::ClassHOW
my $builder := nqp::findmethod(
$compiler_services,'generate_buildplan_executor');
my $method :=
- $builder($compiler_services,$obj,$BUILDALLPLAN);
+ $builder($compiler_services,$obj,self.BUILDALLPLAN($obj));
# We have a generated BUILDALL submethod, so install!
unless $method =:= NQPMu {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment