File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed
Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 38703870\end {codeblock }
38713871\end {example }
38723872
3873+ \pnum
3874+ A virtual function shall not be an explicit object member
3875+ function\iref {dcl.fct }.
3876+ \begin {example }
3877+ \begin {codeblock }
3878+ struct B {
3879+ virtual void g(); // \# 1
3880+ };
3881+ struct D : B {
3882+ virtual void f(this D&); // error: explicit object member function cannot be virtual
3883+ void g(this D&); // overrides \# 1; error: explicit object member function cannot be virtual
3884+ };
3885+ \end {codeblock }
3886+ \end {example }
3887+
38733888\pnum
38743889The \grammarterm {ref-qualifier}, or lack thereof, of an overriding function
38753890shall be the same as that of the overridden function.
Original file line number Diff line number Diff line change 35793579A \grammarterm {member-declarator} with an explicit-object-parameter-declaration
35803580shall not include
35813581a \grammarterm {ref-qualifier} or a \grammarterm {cv-qualifier-seq} and
3582- shall not be declared \keyword {static} or \keyword {virtual} .
3582+ shall not be declared \keyword {static}.
35833583\begin {example }
35843584\begin {codeblock }
35853585struct C {
You can’t perform that action at this time.
0 commit comments