Re: [dev] [dwm] 2000 SLOC - assert() sanity checks

From: Suraj N. Kurapati <sunaku_AT_gmail.com>
Date: Fri, 25 Nov 2011 12:10:53 -0800

On Sun 30 Oct 2011 08:53:48 AM PDT, Martin Kopta wrote:
> 4) Should be the code made smaller by witty constructions or do you
> prefer boring and obvious constructions (which are generaly longer)?

Following this train of thought, what does the suckless community have
to say about sanity checks via <assert.h>? Do you abhor them or deem
them unnecessary? Count them in the SLOC metric or just ignore them?

I ask because I have added an assert() sanity check to my DWM patch,
thereby adding 2 SLOC; but I feel much safer with the assert in place:

https://github.com/sunaku/.dwm/commit/bc43059d4f0c9f87b4a3c43c7a4bc65e1598217f

What do you think?

-- 
From listening comes wisdom and from speaking repentance.

Received on Fri Nov 25 2011 - 21:10:53 CET

This archive was generated by hypermail 2.3.0 : Fri Nov 25 2011 - 21:12:03 CET