Skip to content
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

LWG-3738 has not been implemented? #4549

Closed
hewillk opened this issue Apr 1, 2024 · 1 comment · Fixed by #4551
Closed

LWG-3738 has not been implemented? #4549

hewillk opened this issue Apr 1, 2024 · 1 comment · Fixed by #4551
Labels
enhancement Something can be improved fixed Something works now, yay!

Comments

@hewillk
Copy link
Contributor

hewillk commented Apr 1, 2024

LWG 3738 is recorded as NA in already-closed Meta LWG issue: 2022-11 meeting, It never seems to add the proposed wording though, not sure if this is an oversight.

#define _CONTAINER_DEBUG_LEVEL 2
#include <ranges>

constexpr auto take = std::ranges::take_view(std::views::single(0), -11); // ok
constexpr auto drop = std::ranges::drop_view(std::views::single(0), -11); // error

https://godbolt.org/z/4oMqG6rG1

@hewillk hewillk added the question Further information is requested label Apr 1, 2024
@frederick-vs-ja
Copy link
Contributor

I don't think there's anything to be implemented.

See [expr.const]/6.1:

It is unspecified whether E is a core constant expression if E satisfies the constraints of a core constant expression, but evaluation of E would evaluate

  • an operation that has undefined behavior as specified in [library] through [thread],

@StephanTLavavej StephanTLavavej added enhancement Something can be improved and removed question Further information is requested labels Apr 3, 2024
@StephanTLavavej StephanTLavavej changed the title LWG3738 has not been implemented? LWG-3738 has not been implemented? Apr 3, 2024
@StephanTLavavej StephanTLavavej added the fixed Something works now, yay! label Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Something can be improved fixed Something works now, yay!
Projects
None yet
3 participants