
On Thu, Mar 5, 2009 at 7:11 PM, Beman Dawes <bdawes@acm.org> wrote:
On Thu, Mar 5, 2009 at 12:44 PM, Beman Dawes <bdawes@acm.org> wrote:
On Thu, Mar 5, 2009 at 12:15 PM, Phil Endecott
- How about avoiding the _START/_END stuff with e.g. BOOST_SCOPED_ENUM_DECL(algae, green,red,cyan); (I had been under the impression that varargs macros were a gcc-ism, but I've recently discovered that they're in c99; do non-gcc C++ compilers generally allow them? I don't think we can get away with allowing only up-to-N elements in this case.)
Hum... I hadn't considered varargs macros. If I even knew they existed:-)
Let me try that on some non-gcc compilers. I'll report back.
It looks like Microsoft 2005 and later and at least some others support varargs macros, so I'm investigating further.
I wouldn't. If you really want to use one macro only, I would use the PP sequence instead.
--Beman
-- Felipe Magno de Almeida