Omittable parens is an evil

downs default_357-line at yahoo.de
Sun Jul 20 15:35:25 PDT 2008


Nick Sabalausky wrote:
>> I think it should be used to address to the function itself, like 
>> typeof(func), func.stringof, func.mangleof, etc.
>>
>> func() <- function result
>> &func  <- function pointer
>> func   <- function itself
> 
> I've always liked in other languages where the "function pointer/reference" 
> and "function itself" are considered one and the same. This just seems like 
> extra unnecessary complexity.
> 
> 

For what it's worth, I'd hate that. A symbol is not its address.

It would be the same as saying "float f. I'd like f and &f to be the same. "

It's simply not true.

(I blame C)

 --downs



More information about the Digitalmars-d mailing list