Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] Index of element after width of characters
On 28 October 2015 at 16:59, Peter Stephenson <p.stephenson@xxxxxxxxxxx> wrote:
> On Wed, 28 Oct 2015 16:46:00 +0100
> Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx> wrote:
>> I can resign from the "," and stay with "<" and ">" if Bart agrees.
>> The comma would be more complicated than the rest, having 3 possible
>> values: index, -1, empty string. Having only "<" and ">" it's easy to
>> detect that the limit doesn't divide any char in half:
>
> Mikael's right, actually --- this is an indexing problem and more
> consistently done with subscripts. It should actually be simpler than
> the existing code for space-delimited words in scalars.
Well indexes are substituted there, in e.g. "i -- lowest index of
value matched by subscript", and strings are also supported, so
apparently I should move my code there
Best regards,
Sebastian Gniazdowski
Messages sorted by:
Reverse Date,
Date,
Thread,
Author