Skip to content

Conversation

@dijkstracula
Copy link
Contributor

@dijkstracula dijkstracula commented Jul 9, 2025

This is not a correctness issue, but building semgrep-core currently results in a whole bunch of -Wgnu-designator warnings:

...
bindings.c:64:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   64 |   identifier : "TSNode handling",
      |   ^~~~~~~~~~~~
      |   .identifier =
bindings.c:65:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   65 |   finalize : custom_finalize_default,
      |   ^~~~~~~~~~
      |   .finalize =
bindings.c:66:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   66 |   compare : custom_compare_default,
      |   ^~~~~~~~~
      |   .compare =
bindings.c:67:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   67 |   hash : custom_hash_default,
      |   ^~~~~~
      |   .hash =
bindings.c:68:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   68 |   serialize : custom_serialize_default,
      |   ^~~~~~~~~~~
      |   .serialize =
bindings.c:69:3: warning: use of GNU old-style field designator extension [-Wgnu-designator]
   69 |   deserialize : custom_deserialize_default
      |   ^~~~~~~~~~~~~
      |   .deserialize =
...

This patch adjusts our binding struct declarations so that do not use the old style designator convention, which squelches the warnings.

Security

  • Change has no security implications (otherwise, ping the security team)

This is not a correctness issue, but building semgrep-core currently
results in a whole bunch of -Wgnu-designator warnings.  This patch
adjusts our binding struct declarations so that do not use the old
style designator convention, which squelches the warnings.
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.

2 participants