lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On this day of 03/15/2007 01:48 AM, Brian Hagerty saw fit to scribe:
> The original question was whether the colon-defined function syntax was
> necessary.  Dot-defined function examples add to the case for obviating
> the need for colon-defined functions.

Perhaps in the case of defining functions, yes, but you still need to
figure out how to handle the calling of functions. As I said, if you
were to have only the dot syntax and wanted to detect whether the table
whose member you're calling is to be passed as an argument, you would
need to tag all those functions as being "methods" or not.

How would you solve this problem? That is, how would you tell whether or
not a dot-syntax call should pass the table along as a first argument?

Cheers,
- David

-- 
~David-Haley
http://david.the-haleys.org