Hi, '\b' only match the boundary between alphanumerical char and nonalphanumerical char. I'm wonder if there is a generic metacharacter to match the boundary between any non intersected char set defined in regex and its complement.
For example, I have a few non intersected char sets [a-zA-Z_0-9], [:] and [\s], and lets call the new metacharactor \m. r"abc\m" would be the same as r"abc\b" r"abc:\m' would match "abc:" in r"abc:xy" but not "abc::xy" r"a \m" (with one space) would match "a " (with one space) in "a abc" but not "a abc" (with two spaces). I would like that I have the flexibility to define more non intersected char sets, while I don't want change the regex that I have written. Thanks, Peng -- http://mail.python.org/mailman/listinfo/python-list