ASC2 compiler inlining causes TypeError: Error #1034: Type Coercion failed


following test case reproduces error:

 

air sdk: 3.8.0 build 870 , build 1240

compiler: 2.0.0 build 353981

 

repro:

https://gist.github.com/sigman78/6286715

 

origin: feathers.controls.supportclasses.textfieldviewport

 

causes: [fault] exception, information=typeerror: error #1034: type coercion failed: cannot convert inner@30186e9 flash.display.sprite.

 

'inner' class w/o 'final' or removing -inline compiler option makes error go away

 

test() method bytecode (works, no inlining):

 

 

     [__go_to_definition_help(pos="257")]

     function test():void     /* disp_id=0 method_id=1 nameindex = 3 */

     {

       // local_count=1 max_scope=1 max_stack=2 code_len=12

       // method position=493 code position=645

       0    getlocal0   

       1    pushscope   

       2    debugfile          "c:\sandbox\prj_mono\src;experimental;coercionerror.as"  //stringindex = 26

       4    getlex             private::inner //nameindex = 1

       6    debugline          15

       8    pushtrue     

       9    setproperty        prop //nameindex = 8

       11   returnvoid   

     }

 

 

test() method bytecode (fails, inlines)

[__go_to_definition_help(pos="257")]

     function test():void    /* disp_id=0 method_id=1 nameindex = 3 */

     {

       // local_count=3 max_scope=1 max_stack=2 code_len=35

       // method position=493 code position=645

       0    getlocal0   

       1    pushscope   

       2    debugfile          "c:\sandbox\prj_mono\src;experimental;coercionerror.as"  //stringindex = 26

       4    getlex            private::inner //nameindex = 1

       6    debugline          15

       8    pushtrue     

       9    setlocal2   

       10   setlocal1   

       11   getlocal1   

       12   getsuper          prop //nameindex = 8

       14   getlocal2   

       15   debugline          40

       17   ifne              l1

 

       21   debugline          41

       23   jump              l2

      

       l1:

       27   getlocal2   

       28   getlocal1   

       29   debugline          44

       31   swap         

       32   setsuper          prop //nameindex = 8

      

       l2:

       34   returnvoid   

     }

 

could please open new bug report on over @ https://bugbase.adobe.com

 

once added, please post url others affected can add comments , votes , i'll ask team take look.

 

thanks,

chris



More discussions in AIR Bugs and Performance Issues


adobe

Comments

Popular posts from this blog

Adobe Acrobat Pro , Terminal Server Use

Thread: transmission-daemon isn't playing nice: "409: Conflict"

Thread: gpg: Conflicting Commands