Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!uakari.primate.wisc.edu!aplcen!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn) Newsgroups: comp.lang.c Subject: Re: sizeof a struc field Message-ID: <11316@smoke.BRL.MIL> Date: 17 Oct 89 04:44:35 GMT References: <7710@microsoft.UUCP> <11086@smoke.BRL.MIL> <131@dtoa3.dt.navy.mil> <11227@smoke.BRL.MIL> <7678@cdis-1.uucp> <11263@smoke.BRL.MIL> <10960@riks.csl.sony.co.jp> <11280@smoke.BRL.MIL> <277@dsi.COM> Reply-To: gwyn@brl.arpa (Doug Gwyn) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 12 In article <277@dsi.COM> dave@dsi.UUCP (Dave Rifkind) writes: >Doug Gwyn (I think) says that dereferencing a null pointer is >"syntactically meaningless". Nuts! "Null pointer" is not a syntactic >concept--it's meaningful only at runtime. Any pointer is potentially a >null pointer; you can't determine "nullness" syntactically. To suggest >that a compiler should police runtime errors at compile time is silly. I said that dereferencing a null pointer CONSTANT was meaningless, and it is EXACTLY the kind of thing I want compilers to check for me at compile time. There is no service being rendered by a compiler, when it is in a position to detect a usage error at compile time, silently proceeding to generate code that may blow up at run time.