[temp.explicit] p4 has a vague expound
Nobody has claimed this yet.
- Dominant language
- TeX
- Stars
- 221
- Forks
- 813
- Avg merge
- 16h 4m
- Merged PRs (30d)
- 36
Description
[temp.explicit] p4
If the explicit instantiation is for a class or member class, the elaborated-type-specifier in the declaration shall include a simple-template-id; otherwise, the declaration shall be a simple-declaration whose init-declarator-list comprises a single init-declarator that does not have an initializer.
The intent is, in the explicit instantiation for a class or member class, the declaration of the explicit instantiation shall only be an elaborated-type-specifier. But, that expound does not reflect that meaning.
template<class T>
struct A{
template<class Y>
struct B{};
};
template
template<> struct A<int>::B<int>; // error, the declaration is a explicit-specialization
Is the first sentence should be that
If the explicit instantiation is for a class or member class, the declaration shall be a simple-declaration that omits the init-declarator-list where the defining-type-specifier shall be an elaborated-type-specifier that includes a simple-template-id;
As the manner as the second sentence(emphasized part), which will restrict that the declaration couldn't be anything other than a special elaborated-type-specifier.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with paragraph 4 of [temp.explicit] in the draft and inspect the supplied nested explicit-instantiation example. Compare the current rule with the proposed wording; done means the ambiguity about the declaration form is resolved in the standard text.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, tex
- Domain
- compilers
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100