Subject: Re: IPF in our source tree
To: Martin Husemann <martin@duskware.de>
From: Eric Haszlakiewicz <erh@nimenees.com>
List: tech-kern
Date: 06/01/2007 12:02:11
On Fri, Jun 01, 2007 at 12:06:28PM +0200, Martin Husemann wrote:
> That is not possible. The idiom used by Darren does not work for NetBSD,
> it can not even compile (unless you paper over it with gcc'isms and make
> the macros always return 0, which is not a lot better than the current
> state).
> 
> I suggested to Darren to change the style from
> 
>   int err = 0;
>   err = BCOPYIN(some, args);
> 
> to
> 
>   int err = 0;
>   BCOPYIN(some, args, err);
> 

Why not just define the macro to return 0?  I don't see how that's 
different from having the macro set a variable to 0.
#define BCOPYIN(a,b) (whatever(a,b), 0)
Is there something about this definition that's a gccism?

eric