#1694: load_bytecode semantic differs between .pir and .pbc loading
----------------------+-----------------------------------------------------
 Reporter:  NotFound  |       Owner:       
     Type:  bug       |      Status:  new  
 Priority:  major     |   Milestone:       
Component:  none      |     Version:  2.5.0
 Severity:  high      |    Keywords:       
     Lang:            |       Patch:       
 Platform:            |  
----------------------+-----------------------------------------------------
 This example shows the problem:

 {{{
 # foo.pir

 .sub foo
   say 'foo'
 .end
 }}}

 {{{
 # bar.pir

 .HLL 'bar'

 .sub main :main
     load_bytecode 'foo.pbc'
     foo()
 .end
 }}}

 {{{
 $ parrot bar.pir
 foo
 $ parrot -o foo.pbc foo.pir
 $ parrot bar.pir
 Could not find sub foo
 current instr.: 'main' pc 7 (bar.pir:7)
 }}}

 When loading the pir, either by explicitly asking or, as in this example,
 because the pbc doesn't exist, the semantic changes: the subs are inserted
 in the current HLL if there is no HLL directive in the loaded file.

 See TT #1692

-- 
Ticket URL: <https://trac.parrot.org/parrot/ticket/1694>
Parrot <https://trac.parrot.org/parrot/>
Parrot Development
_______________________________________________
parrot-tickets mailing list
[email protected]
http://lists.parrot.org/mailman/listinfo/parrot-tickets

Reply via email to