-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Labels
bugSomething isn't workingSomething isn't workingfixedSomething works now, yay!Something works now, yay!rangesC++20/23 rangesC++20/23 ranges
Description
When a temporary iter_value_t needs to be constructed, MSVC-STL usually uses copy initialization through iter_value_t<I> val = *it; or iter_value_t<I> val = ranges::iter_move(it);.
However, this is not exposed in the standard concept, both indirectly_movable_storable and indirectly_copyable_storable use constructible_from instead of convertible_to, which does not guarantee that copy-initialization is valid when explicit falls from the sky.
I believe it's extremely pedantic to show an example like this, and I'm not sure it's worth submitting an LWG since Cpp17InputIterator ([iterator.cpp17]) seems to guarantee copy-initialization.
Although based on the current wording we obviously should use direct-initialization.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingfixedSomething works now, yay!Something works now, yay!rangesC++20/23 rangesC++20/23 ranges