Ticket #951: threads.t.patch

File threads.t.patch, 2.0 KB (added by kyle_l5l, 12 years ago)
  • t/pmc/threads.t

    old new  
    447447ok beta3 
    448448OUTPUT 
    449449 
    450 TODO: { 
    451     local $TODO = "vtable overrides aren't properly cloned RT # 46511"; 
    452  
    453     pir_output_is( <<'CODE', <<'OUTPUT', "CLONE_CODE | CLONE_CLASSES; superclass not built-in" ); 
     450pir_output_is( <<'CODE', <<'OUTPUT', "CLONE_CODE | CLONE_CLASSES; superclass not built-in" ); 
    454451.namespace [ 'Foo' ] 
    455452 
    456453.sub foometh :method 
     
    508505    .local pmc thread 
    509506    thread = new ['ParrotThread'] 
    510507    .local pmc _thread_func 
    511     _thread_func = get_global ['main'], 'thread_test_func' 
     508    _thread_func = get_global 'thread_test_func' 
    512509    $I0 = .PARROT_CLONE_CODE 
    513510    bor $I0, $I0, .PARROT_CLONE_CLASSES 
    514511    print "in thread:\n" 
     
    533530Foo? 1 
    534531Bar? 1 
    535532OUTPUT 
    536 } 
    537533 
    538534pir_output_is( <<'CODE', <<'OUTPUT', "CLONE_CODE | CLONE_CLASSES; superclass built-in" ); 
    539535.namespace [ 'Foo' ] 
     
    818814CODE 
    819815 
    820816pir_output_is( 
    821     <<'CODE', <<'OUTPUT', "CLONE_CODE|CLONE_GLOBALS|CLONE_HLL|CLONE_LIBRARIES", todo => 'RT #41373' ); 
     817    <<'CODE', <<'OUTPUT', "CLONE_CODE|CLONE_GLOBALS|CLONE_HLL|CLONE_LIBRARIES" ); 
    822818.HLL 'Perl' 
    823819.loadlib 'perl_group' 
    824820 
     
    829825.sub test 
    830826    .param pmc passed_value 
    831827    .local pmc the_value 
    832     the_value = new ['PerlInt'] 
     828    the_value = new ['Integer'] 
    833829    the_value = 42 
    834     store_global 'Foo', 'x', the_value 
    835     $I0 = typeof passed_value 
    836     $I1 = typeof the_value 
    837     $I0 = $I0 - $I1 
     830    set_global ['Foo'], 'x', the_value 
     831    $S0 = typeof passed_value 
     832    $S1 = typeof the_value 
     833    $I0 = $S0 != $S1 
    838834    print $I0 
    839835    print "\n" 
    840836    .local pmc ns 
     
    848844okay: 
    849845    print "ok (equal)\n" 
    850846 
    851     $I0 = fortytwo 
     847    $I0 = 42 
    852848    print $I0 
    853849    print "\n" 
    854850.end 
     
    865861    bor flags, flags, .PARROT_CLONE_LIBRARIES 
    866862 
    867863    .local pmc passed 
    868     passed = new ['PerlInt'] 
     864    passed = new ['Integer'] 
    869865    passed = 15 
    870866 
    871867    .local pmc thread_func