Boost logo

Boost :

Subject: Re: [boost] Alternative implementation for BOOST_PP_VARIADIC_SIZE
From: Jeffrey Lee Hellrung, Jr. (jeffrey.hellrung_at_[hidden])
Date: 2011-11-14 03:18:07


On Sun, Nov 13, 2011 at 11:53 PM, Paul Mensonides <pmenso57_at_[hidden]>wrote:

> On Sun, 13 Nov 2011 21:10:11 -0800, Jeffrey Lee Hellrung, Jr. wrote:
>
> > I'm just curious, is
> >
> > --------
> > #define A(...)
> > A(,)
> > --------
> >
> > legal?
>
> Yes. "Empty" is a valid argument in >= C99 and >= C++0x. An example of
> when an empty argument actually appears when passing around a cv-
> qualifier: nothing | const | volatile | const volatile. This is only one
> of many many scenarios where emptiness is a valid element and has meaning.
>

Well, in that case, since "clearly" A(,) has two (empty) arguments in its
invocation, one must "clearly" conclude that A() has one (empty) argument
in its invocation. That was more or less the point of my question, and
your logic is sound to me, Paul.

- Jeff


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk