Why can’t I execute an anonymous function directly, like:
var a=function() {return “hello”;} ();
trace(a);
The trace statement should output ‘hello’, but it just outputs ‘undefined’. This is supposed to work in JavaScript (according to Mr Douglas Crockford). I thought Actionscript was compatible with JavaScript in this regard…