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

Fix ODR #4920

Closed
wants to merge 1 commit into from
Closed

Fix ODR #4920

wants to merge 1 commit into from

Conversation

cyyever
Copy link
Contributor

@cyyever cyyever commented Nov 4, 2023

Some static functions should be defined as inline.

@cyyever cyyever marked this pull request as draft November 4, 2023 15:49
@cyyever cyyever force-pushed the fix_odr branch 2 times, most recently from af68f70 to 9eea734 Compare November 4, 2023 15:51
@cyyever cyyever marked this pull request as ready for review November 4, 2023 16:54
@rwgk
Copy link
Collaborator

rwgk commented Nov 4, 2023

Some static functions should be defined as inline.

Nope: all of them are inside struct or class scope, therefore implicitly inline.

https://en.cppreference.com/w/cpp/language/inline

This is very often the case and we never mark them as inline explicitly (I've never seen an argument for explicit inline, unless the implementation is not inside class scope).

I'll close this PR. Please reopen if you think my conclusion is incorrect.

@rwgk rwgk closed this Nov 4, 2023
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