%p and different pointer representations

Karl Heuer karl at haddock.ima.isc.com
Sat Mar 4 07:37:38 AEST 1989


In article <9571 at bloom-beacon.MIT.EDU> scs at adam.pika.mit.edu (Steve Summit) writes:
>In article <11915 at haddock.ima.isc.com> karl at haddock.ima.isc.com (Karl Heuer) writes:
>>Therefore, a completely generic pointer type (to function or data) is
>>`union {void (*)(void); void *}', though I can't think of any practical
>>use for such a thing.
>
>[Symbol table, etc.]

I stand corrected.  I was thinking in terms of using the union as a type pun;
a tagged union (or any other protocol which guarantees that the member fetched
is the one most recently stored) is indeed useful.

Karl W. Z. Heuer (ima!haddock!karl or karl at haddock.isc.com), The Walking Lint



More information about the Comp.lang.c mailing list