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

[class.abstract] Missing change of note for inherited member functions in P1787R6 #6194

Closed

Conversation

frederick-vs-ja
Copy link
Contributor

Before P1787R6, we said members other than constructors could be inherited from a base class. With the changed in #[class.derived] of P1787R6, inherited members are restricted to constructors. As a result, Note 2 in [class.abstract] is incorrect now.

I think we can just say a pure virtual function is declared in a base class. The "see below" part doesn't seem helpful, and I guess it should be removed. Another choice might be removing the whole note since it seems slightly redundant.

Related to cplusplus/CWG#267, but I don't see the need of a core issue.

@tkoeppe
Copy link
Contributor

tkoeppe commented Nov 9, 2023

@opensdh Could you please take a look?

@opensdh
Copy link
Contributor

opensdh commented Nov 10, 2023

I think that the broader changes in cplusplus/CWG#267 are what we want: immediately after the note is a plain use of "has" that is wrong in this conception of inheritance. Fixing that would finish making the note trivial, so we should remove it as part of that change; until then, I suspect the note is helpful in counterbalancing the following mistake.

@tkoeppe
Copy link
Contributor

tkoeppe commented Nov 10, 2023

OK, thanks, let's leave this to that CWG issue!

@tkoeppe tkoeppe closed this Nov 10, 2023
@frederick-vs-ja frederick-vs-ja deleted the no-longer-inherited branch November 10, 2023 01:30
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.

None yet

3 participants