A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://cplusplus.github.io/CWG/issues/1491.html below:

CWG Issue 1491

This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 117a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2025-04-13

1491. Move construction and rvalue reference membersSection: 11.4.5.3  [class.copy.ctor]     Status: CD3     Submitter: Richard Smith     Date: 2012-03-30

According to 11.4.5.3 [class.copy.ctor] paragraph 11, the last bullet, a defaulted move constructor for a class is defined as deleted if

a non-static data member or direct or virtual base class with a type that does not have a move constructor and is not trivially copyable.

This means that an example like

  struct S { S(); int &&r; } s{S()};

is ill-formed. This is probably not intended.

(Note that the February, 2012 proposed resolution for issue 1402 also makes this example ill-formed, because the move constructor is not declared and the copy constructor is defined as deleted because of the rvalue-reference member.)

Additional note, February, 2014:

This issue is resolved by the resolution of issue 1402, which removed the problematic sentence.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4