diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2024-07-10 02:29:34 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2024-07-10 02:29:34 -0700 |
commit | 9ab4fa1b2b6912380fef4a41020b2a369a29473e (patch) | |
tree | bf692c1efe216c8168696ff8ff83d3a5228cca6d /lib.c | |
parent | 7c69a3babde0b80df81fe0311b84113be3cac0ce (diff) | |
download | txr-9ab4fa1b2b6912380fef4a41020b2a369a29473e.tar.gz txr-9ab4fa1b2b6912380fef4a41020b2a369a29473e.tar.bz2 txr-9ab4fa1b2b6912380fef4a41020b2a369a29473e.zip |
split**: split for far negative indices.
* lib.c (split_star_func): In empty index case, convert
sequence via sub(seq, zero, t), so that ranges are properly
expanded. This was done in split_func and partition_func in
recent commits.
* tests/012/seq.tl: Test cases added.
Diffstat (limited to 'lib.c')
-rw-r--r-- | lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -4312,7 +4312,7 @@ static val split_star_func(val base, val lcons) us_rplaca(lcons, first); } } else { - us_rplaca(lcons, seq); + us_rplaca(lcons, sub(seq, zero, t)); us_rplacd(lcons, nil); } break; |