Skip to content

Commit

Permalink
Fix "Out-of-sync package detected" errors
Browse files Browse the repository at this point in the history
We need to clone the braid before setting the current package. Otherwise the
parser doesn't notice when we exit the package.
  • Loading branch information
niner committed Apr 10, 2022
1 parent 9feb903 commit 18004ef
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Raku/Grammar.nqp
Expand Up @@ -1680,6 +1680,7 @@ grammar Raku::Grammar is HLL::Grammar does Raku::Common {
:my $*BORG := {};
:my $*BLOCK;
:my $*PACKAGE;
<!!{ $/.clone_braid_from(self) }>
<longname>? {}
<.stub-package($<longname>)>
{ $/.set_package($*PACKAGE) }
Expand Down

0 comments on commit 18004ef

Please sign in to comment.