On Mon, Jan 06, 2025 at 12:11:47PM +0100, Patrick Steinhardt wrote: > On Fri, Jan 03, 2025 at 02:59:42PM -0500, Jeff King wrote: > > On Fri, Jan 03, 2025 at 02:40:58PM -0500, Jeff King wrote: > > > > > I suspect there's a way to write this as a loop that would be more > > > structured, but it would be a bigger refactor. Bonus points if it also > > > get rid of the try_rename goto, too. ;) > > > > > > I'm OK punting on that, though. > > > > For fun, here's a version without any goto's in it, that should behave > > the same. But it would be very easy to miss a case. So I don't know if > > it is worth the regression risk, and I don't blame you if you delete > > this message without looking carefully. ;) > > > > Diff is kind of hard to read, so you may want to apply (on top of your > > patches) and just look at the post-image. > > Thanks. For now though I think I prefer to go with the simpler diff that > uses goto, as it feels less risky close to v2.48. We can still refactor > this in the next release cycle. Sounds good. I looked over your v2 and it seems fine to me. -Peff