Calling functions via pointers
Jason Zions
jason at hpcnoe.UUCP
Mon Nov 3 08:00:18 AEST 1986
It's a common "corruption" of C, based on the question:
"Shucks, it's a pointer to a function; what the heck else are ya gonna
do with the dang thing except dereference it, i.e. call what it points to?"
Technically, the explicit dereference is required, i.e. ((*action)())
Pcc-based implementation imply the dereference as necessary. I don't even know
if 4.[23] lint would complain about this one.
--
This is not an official statement of Hewlett-Packard Corp., and does not
necessarily reflect the views of HP. It is provided completely without warranty
of any kind. Lawyers take 3d10 damage and roll a saving throw vs. ego attack.
Jason Zions Hewlett-Packard
Colorado Networks Division 3404 E. Harmony Road
Mail Stop 102 Ft. Collins, CO 80525
{ihnp4,seismo,hplabs,gatech}!hpfcdc!hpcnoe!jason
More information about the Comp.lang.c
mailing list