[libcxx-commits] [PATCH] D129823: [libc++][ranges] Make range algorithms support proxy iterators

Jordan Rupprecht via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jul 25 21:10:20 PDT 2022


rupprecht added a comment.

In D129823#3678246 <https://reviews.llvm.org/D129823#3678246>, @var-const wrote:

> @alexfh @jgorbe @rupprecht Thank you for the additional details! I believe the analysis by @huixie90 is spot on and have prepared a patch based on it: https://reviews.llvm.org/D130538
> Can you try out the patch to see if it resolves the issue you're seeing? It does fix the repro case for me.

Thanks! Unfortunately, it just changes the failure that we now see from a crash to a weird runtime failure; incorrectly sorted results, I assume.

I have an alternative change to fix the UB and return `varlen_element &` instead of `varlen_element` (isn't that the eventual fix we should do anyway?), and initial tests seem to be passing now. I'm not sure what D130538 <https://reviews.llvm.org/D130538> is missing.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D129823/new/

https://reviews.llvm.org/D129823



More information about the libcxx-commits mailing list