Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!pasteur!ucbvax!decwrl!sun!pitstop!sundc!seismo!uunet!mcvax!ukc!stl!stc!datlog!scm From: scm@datlog.co.uk ( Steve Mawer ) Newsgroups: comp.lang.c Subject: Re: pointers to arrays Message-ID: <1780@dlvax2.datlog.co.uk> Date: 23 Feb 89 08:23:43 GMT References: <19784@uflorida.cis.ufl.EDU> Reply-To: scm@datlog.co.uk ( Steve Mawer ) Organization: Data Logic Ltd, Queens House, Greenhill Way, Harrow, London. Lines: 20 In article <19784@uflorida.cis.ufl.EDU> thoth@beach.cis.ufl.edu () writes: > If E is an array (yes I know it's upper case but >that's what he used) the &E should return a pointer to an array. My >question is "what will you use this for?" Pointers are usually used >to modify things, and &E I believe would be used to modify the address >of the array since that's what E is (the address of the array). YOU >CAN'T DO THAT!!! &E won't (shouldn't) modify the address since, as you say, it's already cast in stone, so to speak. What it *should* evaluate to is a pointer to the address of the array. This is clearly meaningless (and hence of limited interest :-) since only the compiler should be interested in where it keeps the value of E. Most compilers that I've used will either flag an error, or will issue a warning and *assume* that you meant &E[0] (or just E) and discard the &. -- Steve C. Mawer or < {backbone}!ukc!datlog!scm > Voice: +44 1 863 0383 (x2153)