git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] ewah/bitmap: silence warning about MASK macro redefinition

From
Jeff King <peff@peff.net>
Date
Jun 3, 2015, 06:38 UTC
Message-ID
<20150603063812.GA21319@peff.net>
In-Reply-To
<CAPig+cR3Xt5FNSYbDPhW=m5aEOMq8mCLRSe+mjYfVvdS0R382A@mail.gmail.com>
On Wed, Jun 03, 2015 at 02:28:10AM -0400, Eric Sunshine wrote:
Show 14 quoted lines
> On Wed, Jun 3, 2015 at 12:51 AM, Jeff King <peff@peff.net> wrote:
> > Subject: [PATCH] ewah: use less generic macro names
> >
> > The ewah/ewok.h header pollutes the global namespace with
> > "BITS_IN_WORD", without any specific notion that we are
> > talking about the bits in an eword_t. We can give this the
> > more specific name "BITS_IN_EWORD".
> >
> > Likewise, ewah/bitmap.c uses the generic MASK and BLOCK
> > macro names. These are local to the .c file, but we have the
> > opposite problem: on PowerPC Mac OS X (10.5.8 "Leopard" with
> > Xcode 3.1), system header /usr/include/ppc/param.h[1]
> 
> The [1] has no meaning anymore, so: s/\[1\]//
Oops, I meant to include your footnote.
Show 7 quoted lines
> > I'm also happy to split it into two patches, and make Eric the author on
> > the MASK part.
> 
> I don't mind being an author of a patch, so splitting works for me,
> however, I'm also fine with whatever you and Junio prefer. (And, in
> retrospect, I agree that renaming the macros here is preferable over
> the #undef approach.)

After reflecting, I think splitting it into two patches makes more sense. I mostly noticed that we were touching the same lines, but of course it is not a problem to have two related patches in order. :)

So here is what I propose:
  [1/2]: ewah/bitmap: silence warning about MASK macro redefinition
  [2/2]: ewah: use less generic macro name

I put yours first, because it solves an actual problem. We can drop 2/2 if we decide it's just churn.

-Peff
Previous: Eric SunshineNext: Jeff King
Message 5 of 10 in “ewah/bitmap: silence warning about MASK macro redefinition”
  1. ewah/bitmap: silence warning about MASK macro redefinitionEric Sunshine, Jun 2, 2015
  2. Junio C HamanoJun 2, 2015
  3. Jeff KingJun 3, 2015
  4. Eric SunshineJun 3, 2015
  5. Jeff KingJun 3, 2015
  6. 1/2 ewah/bitmap: silence warning about MASK macro redefinitionJeff King, Jun 3, 2015
  7. Eric SunshineJun 3, 2015
  8. 2/2 ewah: use less generic macro nameJeff King, Jun 3, 2015
  9. Eric SunshineJun 3, 2015
  10. Junio C HamanoJun 3, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.