Browse files

fix examples tests by adding :main tags

  • Loading branch information...
1 parent 23f62f8 commit cdce8c3de6f709433be5c2a3ae4eb7e020a98744 @plobsing plobsing committed Dec 31, 2010
View
2 examples/pasm/fact.pasm
@@ -25,7 +25,7 @@ of the now missing C<clonei>.
=cut
-main:
+.pcc_sub :main main:
new P10, 'ResizableIntegerArray'
set I1,0
## P9 is used as a stack for temporaries.
View
2 examples/pasm/hello.pasm
@@ -11,6 +11,8 @@ for showing how to create an executable from PASM.
=cut
+.pcc_sub :main main:
+
# Get @ARGV as a ResizableStringArray
get_params "0", P0
View
2 examples/streams/Combiner.pir
@@ -25,7 +25,7 @@ Creates the 3 Stream objects and dumps the combined stream.
=cut
-.sub _main
+.sub _main :main
.local pmc counter
.local pmc text
.local pmc combined
View
2 examples/streams/Coroutine.pir
@@ -21,7 +21,7 @@ Creates a coroutine stream and dumps it.
=cut
-.sub _main
+.sub _main :main
.local pmc stream
.local pmc temp
View
2 examples/streams/FileLines.pir
@@ -22,7 +22,7 @@ stream for it. Then it combines the stream with a stream providing line numbers.
=cut
-.sub _main
+.sub _main :main
.param pmc argv
.local int argc
.local pmc file
View
2 examples/streams/Filter.pir
@@ -18,7 +18,7 @@ Creates a counter stream that generates numbers from 0 to 9.
=cut
-.sub _main
+.sub _main :main
.local pmc stream
.local pmc filter
View
2 examples/streams/Include.pir
@@ -13,7 +13,7 @@ Creates a counter stream and dumps it.
=cut
-.sub _main
+.sub _main :main
.local pmc stream
load_bytecode 'Stream/Sub.pbc'
View
2 examples/streams/Lines.pir
@@ -13,7 +13,7 @@ Creates a stream and pipes it through a Stream::Lines stream.
=cut
-.sub _main
+.sub _main :main
.local pmc stream
.local pmc lines
View
2 examples/streams/SubCounter.pir
@@ -13,7 +13,7 @@ Creates a C<Stream::Sub> and dumps it.
=cut
-.sub _main
+.sub _main :main
.local pmc stream
load_bytecode 'Stream/Base.pbc'
View
2 examples/subs/coroutine.pasm
@@ -19,6 +19,8 @@ F<docs/pdds/pdd03_calling_conventions.pod>
=cut
+.pcc_sub :main main:
+
# create a coro and save it on the user stack
.const 'Sub' P0 = "MYCOROUTINE"
# a coroutine carries state - clone it
View
1 examples/subs/pasm_sub1.pasm
@@ -24,6 +24,7 @@ F<docs/pdds/pdd03_calling_conventions.pod>
=cut
+.pcc_sub :main main:
# Fetch a subroutine object
.const 'Sub' P0 = "_sub"
View
2 t/examples/streams.t
@@ -143,7 +143,7 @@ read:[ 21 stream for it. Then it combines the stream with a stream providing l
read:[ 22 ]
read:[ 23 =cut]
read:[ 24 ]
-read:[ 25 .sub _main]
+read:[ 25 .sub _main :main]
read:[ 26 .param pmc argv]
read:[ 27 .local int argc]
read:[ 28 .local pmc file]

0 comments on commit cdce8c3

Please sign in to comment.