ruricolist / serapeum

Utilities beyond Alexandria
MIT License
415 stars 41 forks source link

Allow string designators as separators in `mapconcat` #150

Closed aartaka closed 1 year ago

aartaka commented 1 year ago

I've noticed that most string functions in Serapeum accept string designators for string-ish arguments. But then mapconcat only accepted strings as separators, which might be inconvenient for the character-reliant folks (which I often am one of).

This patch fixes the string-exclusive separators in mapconcat by allowing any string designator. Additionally, simplify the calls to mapconcat and declaim its type.

@ruricolist, any reason it wasn't string designator in the first place?

ruricolist commented 1 year ago

Merged, thanks!