Am Sa., 3. Juni 2023 um 13:23 Uhr schrieb Vladimir Grigoriev via
Std-Discussion <
std-discussion@lists.isocpp.org>:
>
> It seems there is a typo in the table «Table 53: Reference modifications «.
>
> There is written
>
> «If T names a referenceable type then the member typedef type names T&&; otherwise, type names T.»
>
> Instead should it be
>
> «If T names a referenceable type then the member typedef type names T; otherwise, type names T&&.»?
No.
The type trait will *add* an rvalue reference, but it can only do so,
if the type is actually referencable. For example, void is not a
referencable type, so you cannot form void&&, therefore the result is
still void.
Thanks,
- Daniel