QPair: remove user-defined copy assignment operator

The compiler-generated copy assignment operator is fine,
and the user-defined one prevents the compiler from
synthesising a move assignment operator.

Change-Id: I044104a2fd4d7522a910d5c2a68d11dabeca99c4
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This commit is contained in:
Marc Mutz 2012-02-28 22:06:36 +01:00 committed by Qt by Nokia
parent 78faefdbb1
commit 4a82f78dea

View File

@ -57,9 +57,7 @@ struct QPair
QPair() : first(T1()), second(T2()) {}
QPair(const T1 &t1, const T2 &t2) : first(t1), second(t2) {}
QPair<T1, T2> &operator=(const QPair<T1, T2> &other)
{ first = other.first; second = other.second; return *this; }
// compiler-generated copy/move ctor/assignment operators are fine!
T1 first;
T2 second;