regular expressions Definition
Regular expressions are combinations of special character operators, which are symbols that control the search, that you can use to construct search strings for advanced find and/or replace searches.
The regular expressions used to perform searches in the Quartus® Prime software are the same as those used in many Linux applications. For more information about regular expressions, see Jeffrey E.F. Friedl's Mastering Regular Expressions (Sebastopol: O'Reilly & Associates, Inc., 1997).
The table below shows examples of regular expression metacharacters, their descriptions, and their applications:
Operator |
Description |
Example |
---|---|---|
|
Matches any single character of the input line. |
|
|
This metacharacter does not match any character but represents the beginning of the input line. |
|
|
Matches a string of zero or one character that would match the character to the immediate left of ?. |
|
|
This metacharacter does not match any character but represents the end of an input line. |
|
\ |
This metacharacter is used to turn off the special meaning of metacharacters. |
|
|
Matches one or more characters or a range of characters in the set. |
|
|
Matches one or more characters or a range of characters not in the set. |
|
|
Matches a string of one or more characters
that would match the character to the immediate left of
|
|
|
Matches a string of zero or more characters that would match the character to the immediate left of *. |
|
The table below shows how to construct a regular expression search for special characters:
To find: |
Use the regular expression: |
---|---|
newline characters |
|
tabs |
|
.(dot), *, ?, ^, and other metacharacters used in regular expression searches |
|