Created on 2010-09-16.00:00:00 last changed 141 months ago
[Voted into the WP at the March, 2011 meeting.]
Proposed resolution (November, 2010):
This issue is resolved by the resolution of issue 981.
According to 6.9 [basic.types] paragraph 10, a literal class type has
a trivial copy constructor,
no non-trivial move constructor,
...
Is this intended to mean that
struct A {
A(const A&) = default;
A(A&);
};
is a literal class because it does have a trivial copy constructor even though it also has a non-trivial one? That seems inconsistent with the prohibition of non-trivial move constructors.
My preference would be to resolve this inconsistency by dropping the restriction on non-trivial move constructors. It seems to me that having a trivial copy or move constructor is sufficient, we don't need to prohibit additional non-trivial ones. Actually, it's not clear to me that we need the first condition either; a literal type could be used for singleton variables even if it can't be copied.
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2014-03-03 00:00:00 | admin | set | status: fdis -> c++11 |
| 2011-04-10 00:00:00 | admin | set | messages: + msg3302 |
| 2011-04-10 00:00:00 | admin | set | status: ready -> fdis |
| 2010-11-29 00:00:00 | admin | set | messages: + msg3050 |
| 2010-11-29 00:00:00 | admin | set | status: open -> ready |
| 2010-09-16 00:00:00 | admin | create | |