Fixes https://github.com/llvm/llvm-project/issues/52902
In debug mode during constant evaluation the iterator was never assigend. There seem to be no other instances of this bug.
Differential D116346
[libc++] Fix __wrap_iter copy-assignment in constexpr contexts philnik on Dec 28 2021, 3:50 PM. Authored by
Details
Fixes https://github.com/llvm/llvm-project/issues/52902 In debug mode during constant evaluation the iterator was never assigend. There seem to be no other instances of this bug.
Diff Detail
Event TimelineComment Actions LGTM! I recommend that you use a git commit message that includes either Fixes https://github.com/llvm/llvm-project/issues/52902 or simply Fixes #52902, on a line/paragraph by itself. Comment Actions Since this fixes a bug I'd like to see a regression test. The fix itself seems correct. Comment Actions +1, a test is a good idea. But IIUC, this is code which is not yet "active," in the sense that string::begin is not constexpr yet and so it's not really possible to get a std::string::iterator at constexpr time except by default-constructing one.
Comment Actions
Comment Actions LGTM with one minor suggestion, but please wait for the CI to complete.
|