Skip to content

Commit

Permalink
Add a few additional builtins
Browse files Browse the repository at this point in the history
  • Loading branch information
tene committed Dec 24, 2009
1 parent 013fd67 commit cd124c2
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions setup.pir
Expand Up @@ -83,6 +83,7 @@ SOURCES
.param pmc kv :slurpy :named

$P1 = split "\n", <<'BUILTINS_PIR'
steme/builtins/std.pir
steme/builtins/say.pir
steme/builtins/math.pir
steme/builtins/cmp.pir
Expand Down
18 changes: 18 additions & 0 deletions steme/builtins/std.pir
@@ -0,0 +1,18 @@
.sub list
.param pmc l :slurpy
.return (l)
.end

.sub dump
.param pmc a
.local pmc d
load_bytecode 'dumper.pbc'
d = get_root_global ['parrot'], '_dumper'
d(a)
.end

# Local Variables:
# mode: pir
# fill-column: 100
# End:
# vim: expandtab shiftwidth=4 ft=pir:

0 comments on commit cd124c2

Please sign in to comment.