Created on 2009-03-03.00:00:00 last changed 178 months ago
[Voted into WP at July, 2009 meeting.]
Proposed resolution (March, 2009):
Change _N3225_.7.6.4 [dcl.attr.final] paragraph 2 as follows:
If a virtual member function f in some class B is marked final and in a class D derived from B a function D::f overrides B::f, the program is ill-formed; no diagnostic required.[Footnote: If an implementation does not emit a diagnostic it should execute the program as if final were not present. —end footnote]
Notes from the March, 2009 meeting:
This specification was a deliberate decision on the part of the EWG; the general rule was that it should be possible to ignore attributes without changing the meaning of a program. However, the consensus of the CWG was that violation of the [[final]] attribute should require a diagnostic.
According to _N3225_.7.6.4 [dcl.attr.final] paragraph 2, overriding a virtual function with the [[final]] attribute renders a program ill-formed, but no diagnostic is required. This is easily diagnosable and a diagnostic should be required in this case.
History | |||
---|---|---|---|
Date | User | Action | Args |
2010-03-29 00:00:00 | admin | set | status: wp -> cd2 |
2009-11-08 00:00:00 | admin | set | status: dr -> wp |
2009-08-03 00:00:00 | admin | set | messages: + msg2258 |
2009-08-03 00:00:00 | admin | set | status: ready -> dr |
2009-03-23 00:00:00 | admin | set | messages: + msg1890 |
2009-03-23 00:00:00 | admin | set | messages: + msg1889 |
2009-03-03 00:00:00 | admin | create |