Xref: utzoo comp.lang.c++:6865 comp.std.c:2627 Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!cs.utexas.edu!uwm.edu!rpi!brutus.cs.uiuc.edu!jarthur!uci-ics!rfg From: rfg@ics.uci.edu (Ronald Guilmette) Newsgroups: comp.lang.c++,comp.std.c Subject: Re: references to dereferenced null pointers Message-ID: <26035266.26194@paris.ics.uci.edu> Date: 18 Mar 90 09:18:30 GMT References: <51083@microsoft.UUCP> <25EB8EE8.8462@paris.ics.uci.edu> <16179@haddock.ima.isc.com> <10582@alice.UUCP> Reply-To: rfg@ics.uci.edu (Ronald Guilmette) Organization: UC Irvine Department of ICS Lines: 31 In article <10582@alice.UUCP> shopiro@alice.UUCP (Jonathan Shopiro) writes: > > >To me the interesting question in this null pointer business is >whether there is any circumstance where it is legal to say *p >where p is a null pointer. ... >I think the fundamental issue here is when is a pointer dereferenced? >(Since it is clearly illegal to dereference the null pointer). I don't >se why writing ... > > &*p > >should dereference p. I think this discussion is comming full circle. If you scan backwards over the (20-30) postings on this issue you'll note that I said almost exactly this same thing 20-30 messages ago. It was quickly pointed out to me that I was I was being naive (which I now freely admit that I was) because the question becomes confusing if p contains a NULL pointer value. Perhaps we should just take a vote and put the issue to bed. // Ron Guilmette (rfg@ics.uci.edu) // C++ Entomologist // Motto: If it sticks, force it. If it breaks, it needed replacing anyway.