Re: [dwm] using bitaray for tags (PATCH)

From: David Tweed <>
Date: Thu, 22 May 2008 21:07:04 +0100

On Wed, May 21, 2008 at 10:21 AM, Szabolcs Nagy <> wrote:

> probably limiting LENGTH(tags) to 16 is better (simpler, without too
> much compromise (i doubt anyone uses more than 16 tags or X on an
> architecture with less int bits))

I have 26 tags, partly because I put eg gnuplot windows, xdvi windows,
graphical debugger windows, etc, onto their own tags so I can toggle
viewing various combinations of them.

The patch at the end of this thread has

#define TAGMASK ((int)((1LL << LENGTH(tags) + 1) - 1))

Incidentally, I think in the alphabet soup misdesign of C numeric
constants, I suspect the code probably wants 1ULL and given long long
is 64-bits and int is 32-bit on most 64-bit Linux platforms I don't
understand the cast here.

cheers, dave tweed__________________________
Rm 124, School of Systems Engineering, University of Reading.
"while having code so boring anyone can maintain it, use Python." --
attempted insult seen on slashdot
Received on Thu May 22 2008 - 22:07:09 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:43:47 UTC