Subject: Re: bug#78690: 31.0.50; split string: args out of range with TRIM

From: Eli Zaretskii <[email-masked]>
Date: Fri, 06 Jun 2025 10:10:25 +0300

> From: Michael Heerdegen <[email-masked]>
> Cc: [email-masked]
> Date: Fri, 06 Jun 2025 03:53:47 +0200
> 
> Eli Zaretskii <[email-masked]> writes:
> 
> > It is quite obvious that split-string is not prepared to deal with a
> > situation where the argument STRING begins with a match for
> > SEPARATORS.  The breakage here happens because the match for
> > SEPARATORS at the very beginning of STRING also matches TRIM, but even
> > if that is not so, a match for SEPARATORS at the beginning of STRING
> > sets THIS-START incorrectly for the first call to push-one inside the
> > while-loop.
> 
> I read that as "confirmed, a bug".  Ok, thanks for the analysis.

It's more than that: I'm working on this bug.  It just takes time to
unlock all the subtleties of the implementation and understand how to
fix it in a most economical and safe way.  I've just succeeded to
understand what was the root cause when I ran out of time.

The interim analysis was intended to attract others to the problem and
perhaps nudge someone to work out a solution.  Also to serve a
reminder to myself when I get to look at this next time.