Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use 6.e Grammar class as default for grammar decalarations
Do it with EXPORTHOW and specialized HOW metaclass.
- Loading branch information
Showing
6 changed files
with
26 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
use nqp; | ||
|
||
# This constant must specify current CORE revision | ||
# Must preceede class declarations to allow correct recording of their respective language version. | ||
my constant CORE-SETTING-REV = 'd'; | ||
|
||
# vim: ft=perl6 expandtab sw=4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Bind the HOWs into the EXPORTHOW package under the package declarator | ||
# names. | ||
|
||
{ | ||
# Don't expose this name in CORE's namespace | ||
class Perl6::Metamodel::v6e::GrammarHOW | ||
is Perl6::Metamodel::ClassHOW | ||
does Perl6::Metamodel::DefaultParent | ||
{ | ||
} | ||
|
||
# Set 6.e Grammar as the default for grammars | ||
Perl6::Metamodel::v6e::GrammarHOW.set_default_parent_type(Grammar); | ||
EXPORTHOW.WHO<grammar> := Perl6::Metamodel::v6e::GrammarHOW; | ||
} | ||
|
||
# vim: ft=perl6 expandtab sw=4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
use nqp; | ||
|
||
# This constant must specify current CORE revision | ||
# Must preceede class declarations to allow correct recording of their respective language version. | ||
my constant CORE-SETTING-REV = 'e'; | ||
|
||
# vim: ft=perl6 expandtab sw=4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
src/core.e/core_prologue.pm6 | ||
src/core.e/PseudoStash.pm6 | ||
src/core.e/Grammar.pm6 | ||
src/core.e/EXPORTHOW.pm6 |