Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CPreProcessor: support variadic macros with GNU cpp extension syntax #4184

Merged

Conversation

masatake
Copy link
Member

Consider input:

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

With this change,

  • ctags extracts "args" with parameter kind,
  • ctags extracts "debug" with "(format,args...)" as
    the signature field.

The option like

-D'debug(format, args...)=fprintf (stderr, format, args)'

also works with this change.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
Copy link

codecov bot commented Jan 28, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 85.94%. Comparing base (5f8901a) to head (b82d655).
Report is 3 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #4184   +/-   ##
=======================================
  Coverage   85.94%   85.94%           
=======================================
  Files         241      241           
  Lines       59144    59159   +15     
=======================================
+ Hits        50830    50845   +15     
  Misses       8314     8314           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Consider input:

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

With this change,

* ctags extracts "args" with parameter kind,
* ctags extracts "debug" with "(format,args...)" as
  the signature field.

The option like

   -D'debug(format, args...)=fprintf (stderr, format, args)'

also works with this change.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
@masatake masatake force-pushed the cpreprocessor--gnuext-variadic-args branch from df8ac88 to b82d655 Compare January 28, 2025 06:22
@masatake masatake merged commit d2c536c into universal-ctags:master Jan 28, 2025
82 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant