Better AS3 compatibility of primitive types