Subject: Re: [PATCH v3 02/15] xdiff: introduce rust

From: Patrick Steinhardt <[email-masked]>
Date: Fri, 5 Sep 2025 10:23:39 +0200

On Thu, Sep 04, 2025 at 08:45:56AM -0700, Junio C Hamano wrote:
> Patrick Steinhardt <[email-masked]> writes:
> 
> > If we cannot find anything, an alternative could also be to take a very
> > simple subsystem that doesn't see a lot of changes and convert that to
> > Rust. We'd retain both implementations in that case, which I mentioned
> > is painful because we now have to keep both in sync. But if we say that
> > this is a testballoon, only, and that we don't continue to convert other
> > code until Git 3.0, then that might be fine.
> >
> > "varint.c" could be a good match. It's trivial, only 30 lines of code,
> > and completely standalone.
> 
> I am afraid that it is a bit too trivial.  I didn't mention this
> possibility of maintaining parallel implementations, but the
> quiescent area I had in mind was patch-delta.c (no, I am not that
> ambitious to suggest diff-delta.c as the first example).

Oh, it certainly is very trivial. I think for the initial infra this is
a good trait though, as it means that we don't yet have to care about
interop between different parts of Git and can rather focus on the
bigger topic, which is the process for how to introduce Rust in the
first place.

But I agree, once we have the initial Rust infra landed we should then
also gain familiarity with more involved subsystems that _do_ require us
to hook into other subsystems so that we are forced to extend our build
systems as needed.

Patrick