check_names.py cannot have function-name exceptions #187

Open
opened 2025-07-16 10:49:35 -05:00 by davidhorstmann-arm · 1 comment
davidhorstmann-arm commented 2025-07-16 10:49:35 -05:00 (Migrated from github.com)

The comment //no-check-names is supposed to neutralise name checks, but it doesn't work with function names.

This is slightly more complicated to implement than for macros as we do checks on function names then we use nm to check that no symbols are exposed externally that are not declared in headers. We would have to scan for the comment and then remember which function names do not need checking.

With this in mind, would the ability to turn this off even be desirable?

The comment `//no-check-names` is supposed to neutralise name checks, but it doesn't work with function names. This is slightly more complicated to implement than for macros as we do checks on function names then we use `nm` to check that no symbols are exposed externally that are not declared in headers. We would have to scan for the comment and then remember which function names do not need checking. With this in mind, would the ability to turn this off even be desirable?
gilles-peskine-arm commented 2025-07-16 11:19:23 -05:00 (Migrated from github.com)

Nowadays I suspect that clang-tidy's readability-identifier-naming
check
can do what we do with check-names. We should consider this before adding more features to check-names.

Nowadays I suspect that clang-tidy's [readability-identifier-naming check](https://releases.llvm.org/18.1.0/tools/clang/tools/extra/docs/clang-tidy/checks/readability/identifier-naming.html) can do what we do with check-names. We should consider this before adding more features to check-names.
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-Mbed-TLS/mbedtls-framework#187
No description provided.