chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] string-split-fields


From: felix winkelmann
Subject: Re: [Chicken-users] string-split-fields
Date: Sun, 26 Mar 2006 10:02:39 +0200

On 3/25/06, Sunnan <address@hidden> wrote:
> The following expressions:
> (string-split-fields "foo" "foobarfooquuxfoo foo baz foo" #:infix)
> (string-split-fields "foo" "foobarfooquuxfoo foo baz foo" #:suffix)
> (string-split-fields "foo" "foobarfooquuxfoo foo baz " #:infix)
>
> all return the same, while
> (string-split-fields "foo" "foobarfooquuxfoo foo baz " #:suffix)
> dies with an error, which I guess makes sense.
>
> Would you please consider updating the #!:infix variant so that
> (string-split-fields "foo" "foobarfooquuxfoo foo baz foo" #:infix)
> returns an extra "" at the end of the list, to distinguish it from
> (string-split-fields "foo" "foobarfooquuxfoo foo baz " #:infix)

Try this patch (for regex-comon.scm):

57c57
<                           (reverse ms)
---
>                           (reverse (cons "" ms))


cheers,
felix




reply via email to

[Prev in Thread] Current Thread [Next in Thread]