Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!wuarchive!csd4.csd.uwm.edu!cs.utexas.edu!uunet!portal!cup.portal.com!ts From: ts@cup.portal.com (Tim W Smith) Newsgroups: comp.lang.c Subject: Re: pointers to functions Message-ID: <22005@cup.portal.com> Date: 9 Sep 89 09:01:59 GMT References: <1679@hydra.gatech.EDU> <9429@chinet.chi.il.us> Organization: The Portal System (TM) Lines: 23 > K & R are quite definite in stating the correct form is (*f)(), but > apparently even the gods can lie. The Gods got it right. The C compiler for the PDP-11/45 under V6 required (*f)(). f() got an error. I'm not sure, but I think this allowing of f() came in with PCC. It was clearly a bug, which the ANSI committee has chosen to make a feature. While we are on the subject, try this one: (***************f)(); This will also invoke the function on most compilers. Tell me with a straight face that this is not a bug. Does ANSI require this to work? > If f holds the address of the start of the function, *f really doesn't > have any meaning. It certainly does. *f means the function that starts at f. > John Mundt Teachers' Aide, Inc. P.O. Box 1666 Highland Park, IL > john@chinet.chi.il.us