This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/33877] New: Request for __VA_ARGC__


It would be really convenient if the C preprocessor exposed the number of
variable arguments supplied to a variadic macro as an integer.  I tried to come
up with ways of working around this missing feature, but I can't figure out how
to do it without evaluating the macro arguments twice or causing compiler
warnings.

I can supply a patch, if I am blessed with my proposed solution, to have
__VA_ARGC__ be an integer count of the number of __VA_ARGS__.  If you have
suggestions for a better design, I'd like to hear them!

Thanks,
Michael.


-- 
           Summary: Request for __VA_ARGC__
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: michael at fig dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33877


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]