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

[basic.def.odr] Variable templates are not excepted from ODR #3289

Closed
aaronpuchert opened this issue Oct 10, 2019 · 3 comments
Closed

[basic.def.odr] Variable templates are not excepted from ODR #3289

aaronpuchert opened this issue Oct 10, 2019 · 3 comments
Labels
cwg Issue must be reviewed by CWG.

Comments

@aaronpuchert
Copy link

aaronpuchert commented Oct 10, 2019

[basic.def.odr]/12 mentions inline functions, inline variables and function templates, but no variable templates. I think this is an oversight. For example, n4424 says in the introduction: "inline functions can be defined in multiple translation units (and must be defined in all translation units in which they are odr­-used), but all such definitions must be the same. The same is true (through a different mechanism) for functions and variables instantiated from templates."

@zygoloid zygoloid added the cwg Issue must be reviewed by CWG. label Oct 10, 2019
@zygoloid
Copy link
Member

I've requested that Mike open a core issue for this.

@zygoloid
Copy link
Member

Filed as CWG2433.

@aaronpuchert
Copy link
Author

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cwg Issue must be reviewed by CWG.
Projects
None yet
Development

No branches or pull requests

2 participants