While I was trying to build a Number subclass in AS3 I noticed I cannot extend the Number/int/etc. classes --- they are final.
The next best thing was casting. Still, I also don't think this is possible but since I've been asking myself this for a while I said I'd ask here to find out.
Can you create custom casting for a class you created? For example:
var myObject:MyClass = MyClass('string');
And somewhere in MyClass
to be able to set the behavior for converting a String object into it.
If not Flash AS3, than what language allows you to do this? I find it a bit fascinating.