Module Name: src
Committed By: joerg
Date: Thu Nov 8 11:24:01 UTC 2012
Modified Files:
src/external/gpl3/gcc/dist/libstdc++-v3/include/bits: stl_pair.h
Log Message:
Provide copy constructor and copy assignment operators for C++11.
Clang implements the C++11 semantics properly that require the default
to be implicitly deleted.
To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h
diff -u src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h:1.1.1.1 src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h:1.2
--- src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h:1.1.1.1 Tue Jun 21 01:24:41 2011
+++ src/external/gpl3/gcc/dist/libstdc++-v3/include/bits/stl_pair.h Thu Nov 8 11:24:00 2012
@@ -107,6 +107,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
pair(_U1&& __x, _U2&& __y)
: first(std::forward<_U1>(__x)),
second(std::forward<_U2>(__y)) { }
+
+ pair(const pair &) = default;
+ pair(pair &&) = default;
#endif
/** There is also a templated copy ctor for the @c pair class itself. */
@@ -122,6 +125,14 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
second(std::forward<_U2>(__p.second)) { }
pair&
+ operator=(const pair& __p)
+ {
+ first = __p.first;
+ second = __p.second;
+ return *this;
+ }
+
+ pair&
operator=(pair&& __p)
{
first = std::move(__p.first);