Re: New keyword added: continue
- Posted by Matt Lewis <matthewwalkerlewis at gm?il.?om> May 28, 2008
- 765 views
Jason Gade wrote: > > Matt Lewis wrote: > > > > Jason Gade wrote: > > > > > > What is "optional : return_type in function headers"? That sounds like a > > > move > > > away from genericity to me. > > > > You could overload class methods as long as they had different signatures. > > > > ooeu mangled names similar to C++. So you could have two different methods > > with the same name and same number of parameters. The return type helped > > the parser figure out which method to use based upon the return parameters > > from functions. It wasn't enforced in ooeu. > > > Yeah, I had to recheck the docs after CChris mentioned it. > > How does that affect non-method routines? It doesn't, except when they're used as parameters for method calls. Basically, the return type was stored in a slot in the symbol table for each function (defaulted to object, IIRC). It was therefore an additional couple of tokens to parse, and a little bit of additional information in the symbol table that the OO symbol resolution code used. Matt