Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!uhccux!cs211s14 From: cs211s14@uhccux.uhcc.hawaii.edu (Julian Cowley) Newsgroups: comp.lang.c Subject: Re: Pointer/array compatibility Message-ID: <4967@uhccux.uhcc.hawaii.edu> Date: 29 Sep 89 02:38:41 GMT References: <4959@uhccux.uhcc.hawaii.edu> <1989Sep28.205805.9786@jarvis.csri.toronto.edu> Distribution: na Organization: University of Hawaii at Manoa Lines: 22 In article <1989Sep28.205805.9786@jarvis.csri.toronto.edu> flaps@dgp.toronto.edu (Alan J Rosenthal) writes: >I wrote this: >>int a[2][3][5], ***ippp, **ipp, *ip, i, j; >> >>ip = a[0][0]; /* why? */ >>ipp = a[0]; /* why? */ >>ippp = a; /* why? */ > >Well, the answer is that ipp = a[0] and ippp = a are not legal! What compiler >are you using? (rhetorical question) The Ultrix 3.1 cc compiler, which I thought was derived from PCC (i.e., reliable). Even lint does not complain about the expressions. Well, at least that's cleared up. So much for getting concrete answers to simple questions by running a test program through a compiler. Julian Cowley cs211s14@uhccux.uhcc.hawaii.edu cs211s14@uhccux.bitnet