Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
71 additions
and
42 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
|
||
.include 'src/builtins/math.pir' | ||
.include 'src/builtins/say.pir' | ||
.include 'gil/builtins/math.pir' | ||
.include 'gil/builtins/say.pir' | ||
|
||
# Local Variables: | ||
# mode: pir | ||
# fill-column: 100 | ||
# End: | ||
# vim: expandtab shiftwidth=4 ft=pir: | ||
|
File renamed without changes.
File renamed without changes.
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,50 @@ | ||
|
||
=head1 TITLE | ||
|
||
gil.pir - A gil compiler. | ||
|
||
=head2 Description | ||
|
||
This is the base file for the gil compiler. | ||
|
||
This file includes the parsing and grammar rules from | ||
the src/ directory, loads the relevant PGE libraries, | ||
and registers the compiler under the name 'gil'. | ||
|
||
=head2 Functions | ||
|
||
=over 4 | ||
|
||
=item onload() | ||
|
||
Creates thegil compiler using a C<PCT::HLLCompiler> | ||
object. | ||
|
||
=cut | ||
|
||
.namespace [ 'gil::Compiler' ] | ||
|
||
.sub 'onload' :anon :load :init | ||
load_bytecode 'PCT.pbc' | ||
|
||
$P0 = get_hll_global ['PCT'], 'HLLCompiler' | ||
$P1 = $P0.'new'() | ||
$P1.'language'('gil') | ||
$P1.'parsegrammar'('gil::Grammar') | ||
$P1.'parseactions'('gil::Grammar::Actions') | ||
.end | ||
.include 'gil/builtins.pir' | ||
.include 'gil/gen_grammar.pir' | ||
.include 'gil/gen_actions.pir' | ||
=back | ||
=cut | ||
# Local Variables: | ||
# mode: pir | ||
# fill-column: 100 | ||
# End: | ||
# vim: expandtab shiftwidth=4 ft=pir: | ||
File renamed without changes.
File renamed without changes.
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