Wireshark-dev: [Wireshark-dev] Use of variadic macros

From: Peter Wu <peter@xxxxxxxxxxxxx>
Date: Thu, 1 Oct 2015 18:25:24 +0200
Hi,

Use of variadic macros has been discussed in the past
(https://www.wireshark.org/lists/wireshark-dev/201209/msg00142.html),
but at that time it was dropped because it was deemed not supported well
enough across compilers.

Now apparently commit v1.11.3-rc1-2203-geee21a6 added
proto_tree_add_float_format_value which uses variadic macros again and
nobody has complained so far. I also want to use variadic macros in
https://code.wireshark.org/review/10685 because it is natural for format
strings.

GCC 4.4.7/5.2.0 and, Clang 3.0/3.7 and icc 13.0.1 have no issues with
variadic arguments using this test snippet:

    #include <stdio.h>
    #define FOO(fmt, ...) printf(fmt, #__VA_ARGS__, __VA_ARGS__)
    int main() {
      return FOO("%s test %d\n", 1);
    }

at http://gcc.godbolt.org/ with '-Wall -std=c89 -xc.

Are there any objections on removing the variadic arguments restriction?
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl