discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Interesting error in GWorkspace


From: David Chisnall
Subject: Re: Interesting error in GWorkspace
Date: Sun, 11 Sep 2011 20:32:27 +0100

On 11 Sep 2011, at 20:01, Eric Wasylishen wrote:

> I wonder if the clang static analyzer can find places where we send a message 
> returning something other than an object to something that might be nil?

Clang will automatically insert a check that receivers are nil for structure 
returns and substitute a zero-initialised structure instead of doing the 
message send in these cases.  It's done this for about a year, so the simplest 
fix is just to use clang to compile.

The static analyser also warns if you do this, but you only need to bother 
fixing it in code that you intend to compile with gcc.

David

-- Sent from my STANTEC-ZEBRA




reply via email to

[Prev in Thread] Current Thread [Next in Thread]