Skip to main content
Jeff__Ward
Inspiring
January 15, 2014
Question

Alarming bug in AIR SDK 4.0.0.1390, -useLegacyAOT no

  • January 15, 2014
  • 1 reply
  • 1773 views

I've uploaded small testcase which does some simple testing of equivalence of fractions (by parsing Numbers, Strings, etc).  The testcase SWF passes when packaged without -useLegacyAOT no, but fails when using the new halfmoon compiler.  I've filed the following bug:

https://bugbase.adobe.com/index.cfm?event=selectBug&CFGRIDKEY=3694360

This is alarming because it means the new halfmoon compiler feature has changed the logic of the testcase and breaks our app.

I'd appreciate it if someone could download the testcase and confirm this.

Please let me know when this is fixed.  We will not be using -useLegacyAOT no in the mean time.

Best,

-Jeff

This topic has been closed for replies.

1 reply

Jeff__Ward
Inspiring
January 15, 2014

FYI, same result packaing from both Windows and OSX.

January 16, 2014

Hi Jeffward,

     We are able to reproduce the issue at our end , currently we are investigating it.

Thanks for reporting,

-Ankit

Jeff__Ward
Inspiring
April 15, 2014

I've created a radically simplified testcase that isolates the bug.  When creating two instances of a class in a static function, those references are both set to the second instance only when using halfmoon compiler:

https://gist.github.com/jcward/7066bc017bf92531f594

Errant function reproduced here for discussion purposes:

  public class Foo

  {

    public function Foo() {

    }

    static public function something():void

    {

      // Create two unique objects, they cannot be the same

      var A:Foo = new Foo();

      var B:Foo = new Foo();

      Main.t.text += "Created Foo, A="+A+"\n";

      Main.t.text += "Created Foo, B="+B+"\n";

      // But in halfmoon, the references are the same:

      if (A==B) {

        Main.t.text += "ERROR: reference A cannot be equal to B, wth halfmoon?"

        throw new Error("Halfmoon-induced error, A != B");

      } else {

        Main.t.text += "A-OK, two unique Foo references!"

      }

    }

    private var ID:int = Math.random()*0xffffff;

    public function toString():String {

      return "[Foo] " + ID;

    }

  }