Guest User

Untitled

a guest
Oct 16th, 2017
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package  
  2. {
  3.     import flash.display.Sprite;
  4.     import flash.system.Capabilities;
  5.    
  6.     /**
  7.      * ...
  8.      * @author wvxvw
  9.      */
  10.     public class StackUnderflowTest extends Sprite
  11.     {
  12.        
  13.         public function StackUnderflowTest()
  14.         {
  15.             super();
  16.             this.test();
  17.         }
  18.        
  19.         private function test():void
  20.         {
  21.             var problematic:Object = { "a" : 1, "b" : 2, "c" : 3 };
  22.             var i:String;
  23.            
  24.             for (i in problematic)
  25.             {
  26.                 for (var j:String in problematic) { }
  27.                 delete problematic[i];
  28.             }
  29.             for (i in problematic) trace(i);
  30.             trace(Capabilities.version);
  31.         }
  32.        
  33.         /**
  34.         debugfile C:\projects\class\src;;StackUnderflowTest.as
  35.         debugline 19
  36.           //    private function test():void
  37.         getlocal0
  38.         pushscope
  39.         pushnull
  40.         coerce_s
  41.         setlocal2
  42.         pushnull
  43.         coerce_s
  44.         setlocal3
  45.         debug 1,problematic,0,21
  46.         debug 1,i,1,22
  47.         pushstring a
  48.         debugline 21
  49.           //     var problematic:Object = { "a" : 1, "b" : 2, "c" : 3 };
  50.         convert_s
  51.         pushbyte 1
  52.         pushstring b
  53.         convert_s
  54.         pushbyte 2
  55.         pushstring c
  56.         convert_s
  57.         pushbyte 3
  58.         newobject 3
  59.         coerce Object
  60.         setlocal1         // problematic
  61.         debugline 24
  62.           //     for (i in problematic)
  63.         pushbyte 0
  64.         setlocal 4
  65.         getlocal1         // problematic
  66.         coerce_a
  67.         setlocal 5
  68.         jump LOC_1:
  69.         label
  70.         getlocal 5
  71.         getlocal 4
  72.         nextname
  73.         coerce_s
  74.         setlocal2
  75.         debug 1,j,2,26
  76.         debugline 26
  77.           //      for (var j:String in problematic) { }
  78.         pushbyte 0
  79.         setlocal 6
  80.         getlocal1         // problematic
  81.         coerce_a
  82.         setlocal 7
  83.         jump LOC_3:
  84.         label
  85.         getlocal 7
  86.         getlocal 6
  87.         nextname
  88.         coerce_s
  89.         setlocal3
  90.         hasnext2 7,
  91.         iftrue LOC_4:
  92.         kill 7
  93.         kill 6
  94.         debugline 27
  95.           //      delete problematic[i];
  96.         getlocal1         // problematic
  97.         getlocal2         // i
  98.         deleteproperty multinameL
  99.         pop
  100.         debugline 24
  101.           //     for (i in problematic)
  102.         hasnext2 5,
  103.         iftrue LOC_2:
  104.         kill 5
  105.         kill 4
  106.         debugline 29
  107.           //     for (i in problematic) trace(i);
  108.         pushbyte 0
  109.         setlocal 4
  110.         getlocal1         // problematic
  111.         coerce_a
  112.         setlocal 5
  113.         jump LOC_7:
  114.         label
  115.         getlocal 5
  116.         getlocal 4
  117.         nextname
  118.         dup
  119.         setlocal 6
  120.         coerce_s
  121.         setlocal2         // i
  122.         getlocal 6
  123.         kill 6
  124.         pop
  125.         findpropstrict trace
  126.         getlocal2         // i
  127.         callproperty trace,1
  128.         pop
  129.         hasnext2 5,
  130.         iftrue LOC_8:
  131.         kill 5
  132.         kill 4
  133.         debugline 30
  134.           //     trace(Capabilities.version);
  135.         findpropstrict trace
  136.         findpropstrict flash.system:Capabilities
  137.         getproperty flash.system:Capabilities
  138.         getproperty version
  139.         callproperty trace,1
  140.         pop
  141.         debugline 31
  142.           //    }
  143.         returnvoid
  144.         */
  145.     }
  146. }
Add Comment
Please, Sign In to add comment