MPE/iX Shell and Utilities Reference Manual, Vol 2

regexp(3) MPE/iX Shell and Utilities regexp(3)
a) If the initial character is a circumflex ˆ, then this bracket expression is com-
plemented. It shall match any character or collating-element except for the
expressions specified in the bracket expression. For pattern matching, as
performed by the fnmatch() function, this initial character is instead !
(the exclamation mark).
b) If the first character after any potential circumflex is either a dash (-), or a
closing square bracket (]), then that character shall match exactly that char-
acter; that is a literal dash or closing square bracket.
c) Collating sequences may be specified by enclosing their name inside square
bracket period. For example, [.ch.] matches the multi-character collat-
ing sequence ch (if the current language supports that collating sequence).
Any single character is itself. It is an error to give a collating sequence that
isn’t part of the current locale.
d) Equivalence classes may be specified by enclosing a character or collating
sequence inside square bracket equals. For example, [=a=] matches any
character in the same equivalence class as a. This normally expands to all
the variants of a in the current locale: for example, a, \(a:, \(a‘, ... On
some locales it might include both the uppercase and lowercase of a given
character. In the
POSIX locale, this always expands to only the character
given.
e) Within a character class expression (one made with square brackets), the
following constructs may be used to represent sets of characters. These con-
structs are used for internationalization and handle the different collating se-
quences as required by
POSIX.
[:alpha:] Any alphabetic character.
[:lower:] Any lowercase alphabetic character.
[:upper:] Any uppercase alphabetic character.
[:digit:] Any digit character.
[:alnum:] Any alphanumeric character (alphabetic or digit).
[:space:] Any white space character (blank, horizontal tab, vertical
tab).
[:graph:] Any printable character, except the blank character.
[:print:] Any printable character, including the blank character.
Miscellaneous Information 3-33