-
-
Save Mouq/427aad1a5a3817b765ea to your computer and use it in GitHub Desktop.
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
slang FooBar; | |
role Grammar { | |
token baz { } | |
} | |
role Actions { | |
token baz { } | |
} | |
=becomes | |
package FooBar { | |
role ... | |
role ... | |
sub EXPORT { | |
my \HOW = $*LANG<MAIN>.HOW; | |
nqp::bindkey(%*LANG, 'MAIN', HOW.mixin(%*LANG<MAIN>, Grammar)); | |
nqp::bindkey(%*LANG, 'MAIN-actions', HOW.mixin(%*LANG<MAIN-actions>, Actions)); | |
{} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment