-
Notifications
You must be signed in to change notification settings - Fork 782
P2781R9 std::constant_wrapper #8018
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not an authority on indexing.
Did you forget the changes to [span.syn] and [version.syn] or did I overlook something?
struct @\exposid{cw-operators}@ { // \expos | ||
// unary operators | ||
template<@\exposid{constexpr-param}@ T> | ||
friend constexpr auto operator+(T) noexcept -> constant_wrapper<(+T::value)> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
friend constexpr auto operator+(T) noexcept -> constant_wrapper<(+T::value)> | |
friend constexpr auto @\libmember{operator+}{constant_wrapper}@(T) noexcept -> constant_wrapper<(+T::value)> |
Same for all the other operators. Though, constant_wrapper
isn't 100% correct, I believe it's what is most helpful even to implementers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm, this would seem to require a bunch of new escaping. Let's do that later.
5910b2a
to
54ca64f
Compare
54ca64f
to
1c503b2
Compare
Fixes #7969
Fixes cplusplus/papers#1458
Allowed paragraphs to number themselves correctly.
For consistency, did not use code font for constexpr in the phrase "constexpr function".