elisp, The Emacs Lisp Reference Manual}, for a list of character
classes.
-To include a @samp{]} in a character set, you must make it the first
-character. For example, @samp{[]a]} matches @samp{]} or @samp{a}. To
-include a @samp{-}, write @samp{-} as the first or last character of the
-set, or put it after a range. Thus, @samp{[]-]} matches both @samp{]}
-and @samp{-}.
+To include a @samp{]} in a character set, you must make it the first character.
+For example, @samp{[]a]} matches @samp{]} or @samp{a}. To include a @samp{-},
+write @samp{-} as the last character of the set, tho you can also put it first
+or after a range. Thus, @samp{[]-]} matches both @samp{]} and @samp{-}.
To include @samp{^} in a set, put it anywhere but at the beginning of
the set. (At the beginning, it complements the set---see below.)
character alternative. A completely different set of characters is
special inside character alternatives: @samp{]}, @samp{-} and @samp{^}.
-To include a @samp{]} in a character alternative, you must make it the
-first character. For example, @samp{[]a]} matches @samp{]} or @samp{a}.
-To include a @samp{-}, write @samp{-} as the first or last character of
-the character alternative, or put it after a range. Thus, @samp{[]-]}
-matches both @samp{]} and @samp{-}. (As explained below, you cannot
-use @samp{\]} to include a @samp{]} inside a character alternative,
-since @samp{\} is not special there.)
+To include a @samp{]} in a character alternative, you must make it the first
+character. For example, @samp{[]a]} matches @samp{]} or @samp{a}. To include
+a @samp{-}, write @samp{-} as the last character of the character alternative,
+tho you can also put it first or after a range. Thus, @samp{[]-]} matches both
+@samp{]} and @samp{-}. (As explained below, you cannot use @samp{\]} to
+include a @samp{]} inside a character alternative, since @samp{\} is not
+special there.)
To include @samp{^} in a character alternative, put it anywhere but at
the beginning.