Did you try tracing a1.foo? It'll be a type function - and
they're both true. You defined foo as a function within your
you're calling it as if it were either a property or getter,
and it's not
trace(a1.foo() == a2.foo());
Depending on what your foo() function returns, this will be
true or false.