Skip to content

Commit

Permalink
change more deprecated usages of set_addr to set_label in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
NotFound committed Nov 21, 2010
1 parent 6434aa6 commit 8eb855b
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions t/compilers/imcc/reg/alloc.t
Expand Up @@ -7,7 +7,7 @@ use lib qw( . lib ../lib ../../lib );
use Parrot::Test tests => 10;

pir_output_is( <<'CODE', <<'OUT', "alligator" );
# if the side-effect of set_addr/continuation isn't
# if the side-effect of set_label/continuation isn't
# detected this program prints "Hi\nalligator\n"
.sub main :main
Expand All @@ -19,7 +19,7 @@ lab:
dec $I0
unless $I0 goto ex
new $P1, 'Continuation'
set_addr $P1, lab
set_label $P1, lab
$P2 = find_name "alligator"
set_args "0", $P1
invokecc $P2
Expand Down
2 changes: 1 addition & 1 deletion t/compilers/imcc/syn/pcc.t
Expand Up @@ -170,7 +170,7 @@ pir_output_is( <<'CODE', <<'OUT', "coroutine iterator" );
.local int i
i=5
new $P1, 'Continuation'
set_addr $P1, after_loop
set_label $P1, after_loop
loop:
$I2 = _addtwo($P1, i)
print $I2
Expand Down
6 changes: 3 additions & 3 deletions t/op/calling.t
Expand Up @@ -1584,7 +1584,7 @@ pir_output_is( <<'CODE', <<'OUTPUT', "set_args via explicit continuation" );
result = "not ok 2\n"
.local pmc cont
cont = new 'Continuation'
set_addr cont, cont_dest
set_label cont, cont_dest
bar(cont, "ok 1\n")
print "oops\n"
cont_dest:
Expand All @@ -1611,7 +1611,7 @@ pir_output_is( <<'CODE', <<'OUTPUT', "tailcall explicit continuation, no args" )
result = "not ok 2\n"
.local pmc cont
cont = new 'Continuation'
set_addr cont, cont_dest
set_label cont, cont_dest
bar(cont, "ok 1\n")
print "oops\n"
cont_dest:
Expand Down Expand Up @@ -1640,7 +1640,7 @@ pir_output_is( <<'CODE', <<'OUTPUT', "newclosure followed by tailcall" );
.lex "MAIN-CONT", $P41
$I42 = 10
$P41 = new 'Continuation'
set_addr $P41, L2
set_label $P41, L2
goto L3
L2:
get_results '0', $P45
Expand Down
8 changes: 4 additions & 4 deletions t/pmc/continuation.t
Expand Up @@ -32,7 +32,7 @@ Tests the Continuation PMC.

.sub invoke_with_init
$P0 = new ['Continuation']
set_addr $P0, L1
set_label $P0, L1
$P0()
ok(0, "didn't call continuation")
goto end
Expand All @@ -55,7 +55,7 @@ end:
chosen = shift options

cc = new 'Continuation'
set_addr cc, recurse
set_label cc, recurse
paths = get_global '!paths'
push paths, cc

Expand Down Expand Up @@ -111,7 +111,7 @@ end:

# Install top-level cc in global.
cc = new 'Continuation'
set_addr cc, final_failure
set_label cc, final_failure
set_global '!topcc', cc

$P0 = new 'ResizableStringArray'
Expand All @@ -128,7 +128,7 @@ end:

# Install top-level cc in global.
cc = new 'Continuation'
set_addr cc, final_failure
set_label cc, final_failure
set_global '!topcc', cc

$P0 = new 'ResizableStringArray'
Expand Down
2 changes: 1 addition & 1 deletion t/pmc/coroutine.t
Expand Up @@ -60,7 +60,7 @@ pir_output_is( <<'CODE', <<'OUTPUT', "Coroutines - M. Wallace yield example" );
zero = 0
return = new ['Continuation']
set_addr return, return_here
set_label return, return_here
loop:
.begin_call
.call itr, return
Expand Down
2 changes: 1 addition & 1 deletion t/pmc/exception-old.t
Expand Up @@ -458,7 +458,7 @@ handle_errs:
## Take a continuation.
.local pmc cont
cont = new ['Continuation']
set_addr cont, over_there
set_label cont, over_there
print " returning from foo\n"
.return (cont)
over_there:
Expand Down
4 changes: 2 additions & 2 deletions t/pmc/sub.t
Expand Up @@ -66,7 +66,7 @@ pasm_output_is( <<'CODE', <<'OUTPUT', "Continuation" );
set P5, 3
set_global "foo", P5
new P1, ['Continuation']
set_addr P1, endcont
set_label P1, endcont
endcont:
get_global P4, "foo"
print "here "
Expand Down Expand Up @@ -98,7 +98,7 @@ pasm_output_is( <<'CODE', <<'OUTPUT', "definedness of Continuation" );
defined I1, P1
print I1
print "\n"
set_addr P1, cont
set_label P1, cont
defined I1, P1
print I1
print "\n"
Expand Down

0 comments on commit 8eb855b

Please sign in to comment.