Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Testing if a pointer is valid

Received: by 10.68.27.231 with SMTP id w7mr12247331pbg.7.1316868304257;
        Sat, 24 Sep 2011 05:45:04 -0700 (PDT)
Path: lh7ni3915pbb.0!nntp.google.com!news1.google.com!news4.google.com!feeder.news-service.com!87.79.20.101.MISMATCH!newsreader4.netcologne.de!news.netcologne.de!goblin3!goblin.stu.neva.ru!nntp.cprm.net!newsfeeds.sapo.pt!not-for-mail
From: Rui Maciel <rui.mac...@gmail.com>
Reply-To: rui.mac...@gmail.com
Date: Sat, 24 Sep 2011 13:37:03 +0100
User-Agent: KNode/4.4.10
Subject: Re: Testing if a pointer is valid
Newsgroups: comp.lang.c
References: <j5370i$1nv$1@speranza.aioe.org> <H7idnUSmaqgcL-vTnZ2dnUVZ_oGdnZ2d@giganews.com> <j56d81$28s$1@news.xmission.com> <1bipop9mo6.fsf@pfeifferfamily.net> <j5a7cj$itt$1@news.xmission.com> <j5ae7l$u2u$1@dont-email.me> <4e78f388$0$24712$a729d347@news.telepac.pt> <j5auuu$nhb$1@dont-email.me> <4e7a3e84$0$24707$a729d347@news.telepac.pt> <j5dit2$btk$1@dont-email.me> <4e7b5386$0$16751$a729d347@news.telepac.pt> <lnzkhw2zmz.fsf@nuthaus.mib.org>
Followup-To: comp.lang.c
MIME-Version: 1.0
Lines: 20
Message-ID: <4e7dceef$0$16759$a729d347@news.telepac.pt>
Organization: PT.com - Comunicacoes Interactivas, SA
NNTP-Posting-Host: a83-132-113-156.cpe.netcabo.pt
X-Trace: 1316867823 news.telepac.pt 16759 83.132.113.156:33702
X-Complaints-To: abuse@mail.telepac.pt
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 7Bit

Keith Thompson wrote:

> Rui Maciel <rui.mac...@gmail.com> writes:
> [...]
>> If type safety and memory safety is only considered to be at risk due to
>> a programmer's inability to write valid code which goes against the
>> language definition then the point is still the same: a programming
>> language cannot be deemed safe or unsafe due to mistakes made by
>> incompetent programmers.
> 
> What about mistakes made by *competent* programmers?

I don't believe that a competent programmer believes it is reasonable to try 
to access a local object beyond its lifetime, something which at least some 
compilers warn about.  As this was the example which was presented to 
demonstrate that the C programming language is unsafe then, at least in this 
case, this misconception can be put to rest.


Rui Maciel