Re:How quickly can you remove spaces from a string?
by drdrey on Friday January 20, 2017 @03:04PM
(#13446578)
Not all strings are made of English text
[ Parent
| on HN ]
Re:How quickly can you remove spaces from a string?
by sfrailsdev on Friday January 20, 2017 @03:15PM
(#13446646)
you don't even have to go to non english, just utf-8 has stuff like mathematic spaces and spaces of different em sizes. http://perldoc.perl.org/perlrecharclass.html has a reasonably good list of non ascii spaces, though I'm not sure where to dig through for locale specific lists.
That said, while it may not be a solution for every case, it's a solution for the common case and a starting point for other cases, and thus pretty nifty and potentially useful.