HPlogo System Debug Reference Manual: HP 3000 MPE/iX Computer Systems > Appendix A Patterns and Regular Expressions

Character Classes (Match Any One of the Following Characters)

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Index

The metacharacter "[" signals that the characters following, up to the next "]", form a character class, that is, a regular expression that matches any single character from the bracketed list. The character class "[aA]" matches "a" or "A". A dash "-" is used to signify a range of characters in the ASCII collating sequence. For example, "[a-zA-Z]" matches any alphabetic character, while "[0-9]" matches any numeric character. If the first character in a character class is an "^", then any character not in the class constitutes a match; for example, [^a] matches any character except an "a".

Feedback to webmaster