Unicode.Set.to_pattern-exclamation-mark

You're seeing just the function to_pattern-exclamation-mark, go back to Unicode.Set module for more information.
Link to this function

to_pattern!(unicode_set)

View Source

Specs

to_pattern!(binary()) :: [binary()] | no_return()

Transforms a Unicode Set into a pattern that can be used with String.split/3 and String.replace/3.

Arguments

  • unicode_set is a string representation of a Unicode Set

Returns

  • pattern or

  • raises an exception

Example

    iex> pattern = Unicode.Set.to_pattern "[[:digit:]]"
    ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "٠", "١", "٢", "٣",
     "٤", "٥", "٦", "٧", "٨", "٩", "۰", "۱", "۲", "۳", "۴", "۵", "۶",
      "۷", "۸", "۹", "߀", "߁", "߂", "߃", "߄", "߅", "߆", "߇", "߈", "߉"
     "०", "१", "२", "३", "४", "५", "६", "७", ...]