HPlogo System Debug Reference Manual > Appendix A Patterns and Regular Expressions

Literal Expressions (Match Exactly These Characters)

MPE documents

Complete PDF
Table of Contents
Index

E0201 Edition 4 ♥
E0300 Edition 3
E0692 Edition 3

Any literal character, such as "c", is a regular expression and matches that same character in the text being scanned. Regular expressions may be concatenated: a regular expression followed by another regular expression forms a new regular expression that matches anything matched by the first followed immediately by anything matched by the second. A sequence of literal characters is an example of concatenated expressions. For example, "c0000000" or "computer" is a pattern that matches any occurrence of that sequence of characters in the line it is being compared against.

A regular expression is said to match part of a text line if the text line contains an occurrence of the regular expression. For example, the pattern "aa" matches the line "aabc" once at position 1, and the line "aabcaabc" in two places, and the line "aaaaaa" in five (overlapping) places. Matching is done on a line-by-line basis; no regular expression can match across a line boundary.




Appendix A Patterns and Regular Expressions


Metacharacters