A pointer to a 3-D array, or an array of ptrs to 2-D arrays?
Peter da Silva
peter at ficc.uu.net
Thu Nov 16 07:42:47 AEST 1989
In article <2765 at levels.sait.edu.au> MARWK at levels.sait.edu.au writes:
> (1) p = (int (*) [13][2][64]) malloc (sizeof(int) * 13 * 2 * 64)
> *p[i][j][k] = 6
Try !(*p)[i][j][k]!. This is why I wish indirection was postfix. In
"My Ideal C" this would be !p^[i][j][k]!.
(I'm going to start a C-FUTURES mailing list soon, for discussions of
this nature. Mail to peter at ficc.uu.net if you want to join.)
--
`-_-' Peter da Silva <peter at ficc.uu.net> <peter at sugar.hackercorp.com>.
'U` -------------- +1 713 274 5180.
"*Real* wizards don't whine about how they paid their dues"
-- Quentin Johnson quent at atanasoff.cs.iastate.edu
More information about the Comp.lang.c
mailing list