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

Be a bit more explicit with internal and external linkage. #2353

Merged

Conversation

hzeller
Copy link
Collaborator

@hzeller hzeller commented Feb 16, 2025

There are a bunch of functions only really used locally, so make them explicitly static (or put in anonymous namespace). Functiont that are not in header files but are used externally (typically in their corresponding tests): mark explicitly extern.

(Hat-tip to new clang-tidy check [misc-use-internal-linkage])

@hzeller hzeller requested a review from fangism February 16, 2025 16:56
@hzeller hzeller force-pushed the feature-20250216-explicit-linkage branch from f97c466 to 31efaa1 Compare February 16, 2025 17:53
There are a bunch of functions only really used locally, so make
them explicitly static (or put in anonymous namespace).
Functiont that are not in header files but are used externally
(typically in their corresponding tests): mark explicitly extern.

(Hat-tip to new clang-tidy check `[misc-use-internal-linkage]`)
@hzeller hzeller force-pushed the feature-20250216-explicit-linkage branch from 31efaa1 to 7f0bc2e Compare February 16, 2025 22:19
@hzeller hzeller merged commit 005007b into chipsalliance:master Feb 17, 2025
33 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