8 ms·
I hope one of the parts deals with people's aversion to C declarations. The declaration syntax allows vastly complicated data definition, and the fact that decl
by codgercoder 14y ago
I hope one of the parts deals with people's aversion to C declarations. The declaration syntax allows vastly complicated data definition, and the fact that declaration looks like use simplifies things immensely.
(I also have a personal style quibble -- lots of people seem to think that putting spaces around every lexical element clarifies things; I think it just makes gassy code.)
- comex 14y agoAs a fan of C, I have to disagree. To quote OS X's `man signal`: void (*signal(int sig, void (*func)(int)))(int); or in the equivalent but easier to read typedef'd version: typedef void (*sig_t) (int); sig_t signal(int sig, sig_t func); In, say, Go, this would be func signal(sig int, newFunc func(int)) func(int) which imo is cleaner (it's clear that the second argument and return value have the same type, without having to use a typedef) without sacrificing power.
- deleted 14y ago[deleted]