Next: , Previous: , Up: Dictionary for Unicode Concepts   [Contents][Index]

13.3.4 Sequences

Since strings are also sequences, the sequence functions can be used on strings. We note here some issues with these functions. Most issues are due to the fact that strings are UTF-16 strings and characters are UTF-16 code units, not Unicode codepoints.

Function: remove-duplicates sequence &key :from-end :test :test-not :start :end :key
Function: delete-duplicates sequence &key :from-end :test :test-not :start :end :key

Because of surrogate pairs these functions may remove a high or low surrogate value, leaving the string in an invalid state. Use these functions carefully with strings.