Unicode.Set.to_regex_string
You're seeing just the function
to_regex_string
, go back to Unicode.Set module for more information.
Specs
Transforms a Unicode Set into a regex
string that can be used as an argument
to Regex.compile/1
.
Arguments
unicode_set
is a string representation of a Unicode Set
Returns
{:ok, regex_string}
or{:error, {exception, reason}}
Example
iex> Unicode.Set.to_regex_string "[[:Zs]-[ ]]"
{:ok, "[\x{3A}\x{5A}\x{73}]"}