Acknowledged

Regression - arrays are totally broken (SDK 4.1.2)

var arr = ["A", "B"];
arr.toString();

Gives

Error: Unhandled Exception
Exception: UnexpectedTypeException: Expected Number/Float/Long/Double/Char, given Number/Array

var arr = ["A", "B"];
for (var i = 0; i < arr.size(); i++) {
    arr[i];
}

Gives

Error: Unhandled Exception
Exception: UnexpectedTypeException: Expected Number/Float/Boolean/Long/Double, given Object

var arr = new Lang.Array();
arr.add("A");

Gives

Error: Unhandled Exception
Exception: UnexpectedTypeException: Expected Array, given String

SDK version 4.1.2.

Parents
  • > And I can't build against 4.1.7 because of all the regressions with the type system.

    You can turn off type checking in the Monkey C extension preferences (either globally or per-workspace). You can also disable type checking on a per-project basis by adding the following line to monkey.jungle:

    project.typecheck=0

Comment
  • > And I can't build against 4.1.7 because of all the regressions with the type system.

    You can turn off type checking in the Monkey C extension preferences (either globally or per-workspace). You can also disable type checking on a per-project basis by adding the following line to monkey.jungle:

    project.typecheck=0

Children
No Data