[haiku-commits] Re: r40399 - in haiku/trunk/src/add-ons/mail_daemon/inbound_protocols/imap: . imap_lib

  • From: Clemens <clemens.zeidler@xxxxxxxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Thu, 10 Feb 2011 08:54:08 +1300

On Wed, 09 Feb 2011 23:26:00 +1300, Jérôme Duval <korli@xxxxxxxxxxxxxxxx> wrote:

You could save a NULL check here and also use if (handler == NULL)
instead of if (!handler)

Just a remark and sorry if I missed the discussion...

for me (!handler) is as readable as (handler == NULL), the later is more accurate and shows that the variable is a pointer but its also more work to code. On the other side you should also be able to distinct bool variables and pointers if there are named probably, e.g. would named a bool isHandler.

I would be fine with both, one rule less in the guide line...


Other related posts: