EricWF accepted this revision.
EricWF added a comment.
This revision is now accepted and ready to land.
The changes to `<optional>` LGTM but not the ones to `<experimental/optional>`
Unfortunately libc++'s `<experimental/optional>` doesn't yet implement LFTS v2
so all of the other non-const observers are also not constexpr in our
implementation. I think updating `<experimental/optional>` to LFTS v2 should be
done as a separate patch. Please back out the changes to
`<experimental/optional>` before committing.
================
Comment at:
test/std/experimental/optional/optional.object/optional.object.observe/value_or.pass.cpp:48
+ if (!(std::move(opt).value_or(y) == 2)) std::abort();
+ if (!(*opt == 0)) std::abort();
}
----------------
This test doesn't compile since the non-const version of
`std::experimental::optional::operator*()` isn't constexpr.
https://reviews.llvm.org/D27850
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits