From 447c55d16e237a9df687fcf96f3d696972afec07 Mon Sep 17 00:00:00 2001 From: Jens Maurer Date: Thu, 3 Oct 2019 00:07:58 +0200 Subject: [PATCH] [expr.typeid] Add note highlighting prohibition of bad function types. Function types that can only be used for member functions (because they have cv-qualifiers or a ref-qualifier) cannot appear as a typeid operand. --- source/expressions.tex | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/expressions.tex b/source/expressions.tex index 8ff85e8736..493e75a5c5 100644 --- a/source/expressions.tex +++ b/source/expressions.tex @@ -3566,6 +3566,10 @@ representing the cv-unqualified referenced type. If the type of the \grammarterm{type-id} is a class type or a reference to a class type, the class shall be completely-defined. +\begin{note} +The \grammarterm{type-id} cannot denote a function type with +a \grammarterm{cv-qualifier-seq} or a \grammarterm{ref-qualifier}\iref{dcl.fct}. +\end{note} \pnum If the type of the expression or \grammarterm{type-id} is a