[libcxx-commits] [PATCH] D119374: [libc++] Remove conditional noexcepts from view_interface

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Feb 9 13:29:15 PST 2022


Quuxplusone created this revision.
Quuxplusone added reviewers: ldionne, zoecarver, Mordante, philnik, var-const, jloser, libc++.
Quuxplusone added a project: libc++.
Quuxplusone requested review of this revision.
Herald added a subscriber: libcxx-commits.
Herald added 1 blocking reviewer(s): libc++.

As suggested in D117966 <https://reviews.llvm.org/D117966> (attn @ldionne).
These conditional noexcepts are *permitted* by the Standard (as long
as there were no mistakes in them, I guess); but not *mandated*.
The Standard doesn't put any noexcept-specifications on these member functions.
The same logic would apply to `transform_view::iterator::operator*`
and `transform_view::iterator::operator[]`, but the Standard mandates
conditional noexcept on `iter_move(transform_view::iterator)`, and
I think it doesn't make much sense to say "moving from this iterator
is conditionally noexcept but not-moving from it is noexcept(false),"
so I'm leaving transform_view alone for now.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D119374

Files:
  libcxx/include/__ranges/view_interface.h
  libcxx/test/std/ranges/range.utility/view.interface/view.interface.pass.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D119374.407274.patch
Type: text/x-patch
Size: 8697 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20220209/4c750be7/attachment.bin>


More information about the libcxx-commits mailing list