public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* macro conflict
@ 2001-08-23 19:03 J. Imlay
  2001-08-23 19:21 ` Alan Cox
                   ` (2 more replies)
  0 siblings, 3 replies; 22+ messages in thread
From: J. Imlay @ 2001-08-23 19:03 UTC (permalink / raw)
  To: linux-kernel

IN getting the AFS kernel modules to compile under linux I dicovered that
the were useing the standard min(x,y) macro that whould evaluate which one
is smaller. However sometime between 2.4.6 and 2.4.9 a new macro was added
to linux/kernel.h

this one:

#define min(type,x,y) \
        ({ type __x = (x), __y = (y); __x < __y ? __x: __y; })

the old one is

#define min(x,y) ( (x)<(y)?(x):(y) )

has been around a lot longer and is in lots of header files.

The problem here with AFS is that it needs the old definition but the old
definition is being over written by the new one... you guys should know
all this. But I am just saying that I really think the new macro
min(type,x,y) should get a new name. like type_min or something.

Thanks,

Josie Imlay


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2001-08-24 21:18 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-08-23 19:03 macro conflict J. Imlay
2001-08-23 19:21 ` Alan Cox
2001-08-23 19:34 ` Tim Walberg
2001-08-23 20:01   ` Alan Cox
2001-08-23 20:02   ` raybry
2001-08-23 20:16     ` Magnus Naeslund(f)
2001-08-23 20:27       ` Alan Cox
2001-08-23 20:29         ` Magnus Naeslund(f)
2001-08-23 23:18       ` Andrew Cannon
2001-08-23 23:37         ` Magnus Naeslund(f)
2001-08-23 23:35       ` Roman Zippel
2001-08-24  1:42     ` Camiel Vanderhoeven
2001-08-24 13:03 ` David Woodhouse
2001-08-24 13:15   ` Keith Owens
2001-08-24 13:17     ` David Woodhouse
2001-08-24 14:20       ` Bill Pringlemeir
2001-08-24 21:17         ` Roman Zippel
2001-08-24 13:34   ` Richard B. Johnson
2001-08-24 18:20     ` David Wagner
2001-08-24 17:25   ` Alex Bligh - linux-kernel
2001-08-24 17:34   ` David Woodhouse
2001-08-24 18:12     ` Bill Pringlemeir

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox