Static instances will always be less expensive at runtime over stack allocations. On Jan 16, 2012 10:28 AM, "Nicholas Kwiatkowski" <nicho...@spoon.as> wrote:
> Sure -- but you would remove compile-time checking and optimization, which > has some performance impacts (this moves the object type checks to runtime, > vs. compile time, at a performance determent). That would > move convenience over performance, where if you allow overloading, the two > would be equal. > > I'm not saying we would be able to accomplish anything we can't today -- > but it would be much more convenient for some to have it available as a > resource. > > -Nick > > On Mon, Jan 16, 2012 at 10:09 AM, David Arno <da...@davidarno.org> wrote: > > > > From: Nicholas Kwiatkowski [mailto:nicho...@spoon.as] > > > Sent: 16 January 2012 15:02 > > > > > public function sendAsString(stringToSend:String):bool > > > public function sendAsBool(boolToSend:Boolean):bool > > > public function sendAsArray(arrayToSend:Array):bool > > > public function sendAsInt(intToSend:int):bool ... > > > > Could you not just have: > > > > public function send(value:*):Boolean > > > > instead? > > > > David. > > > > >