mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1885840 - Clarify comment in TestMaybe on why move operations unexpectedly work with a non-movable type. r=glandium
As Bug 1601251 states, those operations need to be explicitly deleted for the asserts to hold. Differential Revision: https://phabricator.services.mozilla.com/D204990
This commit is contained in:
parent
fbe4b71f35
commit
3a4d791e34
@ -530,7 +530,8 @@ static bool TestCopyAndMove() {
|
||||
|
||||
static_assert(std::is_copy_constructible_v<Maybe<UnmovableValue>>);
|
||||
static_assert(std::is_copy_assignable_v<Maybe<UnmovableValue>>);
|
||||
// XXX Why do these static_asserts not hold?
|
||||
// TODO(Bug 1601251): Maybe<T> should delete move operations if T does not
|
||||
// support moves
|
||||
// static_assert(!std::is_move_constructible_v<Maybe<UnmovableValue>>);
|
||||
// static_assert(!std::is_move_assignable_v<Maybe<UnmovableValue>>);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user