|
2162 | 2162 | the postfix expression shall be either an lvalue that refers to a
|
2163 | 2163 | function (in which case the function-to-pointer standard
|
2164 | 2164 | conversion\iref{conv.func} is suppressed on the postfix expression),
|
2165 |
| -or it shall have function pointer type. Calling a function through an |
2166 |
| -expression whose function type is different |
2167 |
| -from the function type of the called function's |
2168 |
| -definition results in undefined behavior\iref{dcl.link}. For a call to a non-static |
| 2165 | +or it shall have function pointer type. |
| 2166 | + |
| 2167 | +\pnum |
| 2168 | +For a call to a non-static |
2169 | 2169 | member function,
|
2170 | 2170 | the postfix expression shall be an
|
2171 | 2171 | implicit~(\ref{class.mfct.non-static}, \ref{class.static}) or explicit
|
|
2179 | 2179 | A member function call of the form \tcode{f()} is interpreted as
|
2180 | 2180 | \tcode{(*this).f()} (see~\ref{class.mfct.non-static}).
|
2181 | 2181 | \end{note}
|
2182 |
| -If a function or member function name is used, the name can be |
2183 |
| -overloaded\iref{over}, in which case the appropriate function |
2184 |
| -shall be selected according to the rules in~\ref{over.match}. If the selected |
| 2182 | + |
| 2183 | +\pnum |
| 2184 | +If a function or member function name is used, |
| 2185 | +the appropriate function and the validity of the call are determined |
| 2186 | +according to the rules in~\ref{over.match}. If the selected |
2185 | 2187 | function is non-virtual, or if the \grammarterm{id-expression} in the class
|
2186 | 2188 | member access expression is a \grammarterm{qualified-id}, that function is
|
2187 | 2189 | called. Otherwise, its final overrider\iref{class.virtual} in the dynamic type
|
|
2212 | 2214 | \indextext{type!incomplete}%
|
2213 | 2215 | This return type shall be an object type, a reference type or \cv{}~\tcode{void}.
|
2214 | 2216 |
|
| 2217 | +\pnum |
| 2218 | +Calling a function through an |
| 2219 | +expression whose function type is different |
| 2220 | +from the function type of the called function's |
| 2221 | +definition results in undefined behavior\iref{dcl.link}. |
| 2222 | + |
2215 | 2223 | \pnum
|
2216 | 2224 | \indextext{function argument|see{argument}}%
|
2217 | 2225 | \indextext{function parameter|see{parameter}}%
|
|
0 commit comments