Couple of thoughts:

Yes, ActionScript is going to be compared against other languages.  We
simply don't want to make that the decision point.  Developer productivity
is what we need to deliver.  MXML and AS are our starting point because
that is what we own.  Really, if folks wanted to glue their MXML together
with TypeScript or Haxe, I would have no problem with folks making that
happen.  Adding features that improve developer productivity are worth
doing.


I guess I'll have to run a test in Java, but the key thing about runtime
type checking and conversion is something like this:

var foo:* = "Test String";
var bar:ArrayList.<String> = foo; // should throw an type-mismatch error
since a single String is not an ArrayList of strings.

Substitute Vector for ArrayList and the Flash runtime will catch it.  Not
sure what we'll generate in ABC so it gets caught.

Then there is:

var foo:ArrayList.<Object> = new ArrayList.<Object>([new
ValueObject("obj1"), new ValueObject("obj2")]);
var bar:ArrayList.<ValueObject> = foo;  // ok
var baz:ArrayList.<String> = foo; // not ok

I always figured Java checked for this at runtime, but maybe not.

-Alex

Reply via email to