void * and pointers to functions
mdivax1!robinson
mdivax1!robinson
Thu Jul 26 07:32:57 AEST 1990
It is my understanding of K&R I C that a variable of type char * may only
contain a pointer to a data object, and that assigning a pointer to a
function to such a variable is not guaranteed to work since there is no
requirement that pointers to objects be the same size as pointers to
functions.
After reading the relevant parts of K&R II it would appear that a variable of
type void * may legally contain a pointer to a function as well as a
pointer to any of the various data types. Is this correct?
--
Jim Robinson
{uunet,ubc-cs}!van-bc!mdivax1!robinson
More information about the Comp.lang.c
mailing list