Menu

#5 No support for ... inside MACRO.

open-later
nobody
None
5
2014-08-19
2003-01-13
No

I have this include file in most of my software which
I'm attaching to the bug.

Splint seems to be recognizing the ... has an invalid
character:

../include/i386/colubris/output.h:23:53: invalid
character in macro parameter name
../include/i386/colubris/output.h:23:53: Parameter list
for #define is not parseable
../include/i386/colubris/output.h:24:51: invalid
character in macro parameter name
../include/i386/colubris/output.h:24:51: Parameter list
for #define is not parseable
../include/i386/colubris/output.h:25:57: invalid
character in macro parameter name
../include/i386/colubris/output.h:25:57: Parameter list
for #define is not parseable
../include/i386/colubris/output.h:26:51: invalid
character in macro parameter name
../include/i386/colubris/output.h:26:51: Parameter list
for #define is not parseable
../include/i386/colubris/output.h:27:55: invalid
character in macro parameter name
../include/i386/colubris/output.h:27:55: Parameter list
for #define is not parseable

This syntax is now part of the C99 specification and
therefore I believe it should be supported by splint.

Discussion

  • Jakub Narebski

    Jakub Narebski - 2003-03-02

    Logged In: YES
    user_id=113337

    Workaround for GCC: use named ... (this is GNU CPP
    extension) in macro definition. For example

    #define eprintf(format, args...) fprintf(stderr, format, ##
    args)

    works fine (no errors from splint-3.0.1.6-2 (RedHat RPM)), while

    #define eprintf(...) fprintf (stderr, __VA_ARGS__)

    gives:

    macros.h:25:51: invalid character in macro parameter name
    macros.h:25:51: Parameter list for #define is not parseable
    Preprocessing error for file:
    /home/jnareb/publikacja/programy/flambda_fft/macros.h
    *** Cannot continue.

     
  • David Larochell

    David Larochell - 2003-03-04
    • status: open --> open-later
     
  • David Larochell

    David Larochell - 2003-03-04

    Logged In: YES
    user_id=61835

    We're still working on full support for C99.

    Unfortunately this is one of the features we do not
    currently support.

    We hope to support this in the future.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.