improve string-split-lens error message
This commit is contained in:
parent
c7b5783088
commit
6af441c592
|
@ -21,7 +21,7 @@
|
||||||
[(string? sep) (regexp (regexp-quote sep))]
|
[(string? sep) (regexp (regexp-quote sep))]
|
||||||
[(char? sep) (regexp (regexp-quote (string sep)))]
|
[(char? sep) (regexp (regexp-quote (string sep)))]
|
||||||
[(regexp? sep) sep]
|
[(regexp? sep) sep]
|
||||||
[else (error 'bad)]))
|
[else (error 'string-split-lens "expected a string, char, or regexp, given: ~v" sep)]))
|
||||||
(define (get str)
|
(define (get str)
|
||||||
(map string->immutable-string (regexp-split sep-rx str)))
|
(map string->immutable-string (regexp-split sep-rx str)))
|
||||||
(define (set str lst)
|
(define (set str lst)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user