Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(241)

Unified Diff: base/template_util_unittest.cc

Issue 2790403003: Remove base::is_*assignable as these are now in the linux sysroot. (Closed)
Patch Set: isassign: removed-tests Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/template_util.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/template_util_unittest.cc
diff --git a/base/template_util_unittest.cc b/base/template_util_unittest.cc
index 921596474b6d9a38991506396a1c64148025885d..e34a25b0428b4f8ef9e9d001978116aa5adb3cdb 100644
--- a/base/template_util_unittest.cc
+++ b/base/template_util_unittest.cc
@@ -30,39 +30,6 @@ static_assert(!is_non_const_reference<const int&>::value,
"IsNonConstReference");
static_assert(is_non_const_reference<int&>::value, "IsNonConstReference");
-class AssignParent {};
-class AssignChild : AssignParent {};
-
-// is_assignable<Type1, Type2>
-static_assert(!is_assignable<int, int>::value, "IsAssignable"); // 1 = 1;
-static_assert(!is_assignable<int, double>::value, "IsAssignable");
-static_assert(is_assignable<int&, int>::value, "IsAssignable");
-static_assert(is_assignable<int&, double>::value, "IsAssignable");
-static_assert(is_assignable<int&, int&>::value, "IsAssignable");
-static_assert(is_assignable<int&, int const&>::value, "IsAssignable");
-static_assert(!is_assignable<int const&, int>::value, "IsAssignable");
-static_assert(!is_assignable<AssignParent&, AssignChild>::value,
- "IsAssignable");
-static_assert(!is_assignable<AssignChild&, AssignParent>::value,
- "IsAssignable");
-
-struct AssignCopy {};
-struct AssignNoCopy {
- AssignNoCopy& operator=(AssignNoCopy&&) { return *this; }
- AssignNoCopy& operator=(const AssignNoCopy&) = delete;
-};
-struct AssignNoMove {
- AssignNoMove& operator=(AssignNoMove&&) = delete;
- AssignNoMove& operator=(const AssignNoMove&) = delete;
-};
-
-static_assert(is_copy_assignable<AssignCopy>::value, "IsCopyAssignable");
-static_assert(!is_copy_assignable<AssignNoCopy>::value, "IsCopyAssignable");
-
-static_assert(is_move_assignable<AssignCopy>::value, "IsMoveAssignable");
-static_assert(is_move_assignable<AssignNoCopy>::value, "IsMoveAssignable");
-static_assert(!is_move_assignable<AssignNoMove>::value, "IsMoveAssignable");
-
// A few standard types that definitely support printing.
static_assert(internal::SupportsOstreamOperator<int>::value,
"ints should be printable");
« no previous file with comments | « base/template_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698