Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Who needs functional programming...

Name: Anonymous 2015-07-27 20:45

... when C has function pointers?

Name: Anonymous 2015-07-28 10:03

>>8
Shouldn't this work fine?
struct fp
{
struct fp *(*func)(void *);
};


C doesn't even have a generic function pointer type on all implementations
I fail to see how a generic function pointer would be of use, but you can always return a void * that you then cast into a pointer to a struct that contains the function pointer you want.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List