Re: [dwm] malloc'ed client in manage()

From: Anselm R Garbe <garbeam_AT_gmail.com>
Date: Mon, 8 Sep 2008 19:18:21 +0100

2008/9/8 Szabolcs Nagy <nszabolcs_AT_gmail.com>:
> On 9/8/08, markus schnalke <meillo_AT_marmaro.de> wrote:
>> [2008-09-07 21:24] Filippo Erik Negroni <f.e.negroni_AT_googlemail.com>
>>>
>>> Code that sucks less is code that compiles for many years to come, and
>>> strives for maximum portability, within reason.
>>
>> ... or is it code that's easy to understand and therefor easy to
>> maintain?
>>
>>
>> Pike and Kernighan call it:
>> simplicity --- clarity --- generality
>
> relying on pointer 0 == integer 0 is simple and general
> (more general than relying on c99 not to mention posix, x11, ..)
>
> but if we really care about obscure 30 year old cpus (other than x86
> :)) then i'd go with my solution: c = malloc(); and *c = (Client){};

Well, I agree on this proposal and go for it. It is fairly simple and
nice looking imho.

Kind regards,
--Anselm
Received on Mon Sep 08 2008 - 18:18:21 UTC

This archive was generated by hypermail 2.2.0 : Mon Sep 08 2008 - 18:24:06 UTC