purescript-strings
purescript-strings copied to clipboard
Add a `isWellFormed` function?
Could we provide a function that checks if a string is wellformed w.r.t. its encoding? In the JS backend this would be a check if there are lone surrogates present, in other backends this may be a different check. This would allow one to check if a string is well formed, after which one doesn't have to deal with invalid encoded string situations.