minor fixes

This commit is contained in:
Ilya Kantor 2020-07-05 12:45:21 +03:00
parent 26bf51af3e
commit 0edc6518de

View file

@ -25,7 +25,7 @@ So, it matches the pattern `pattern:\bHello\b`, because:
1. At the beginning of the string matches the first test `pattern:\b`. 1. At the beginning of the string matches the first test `pattern:\b`.
2. Then matches the word `pattern:Hello`. 2. Then matches the word `pattern:Hello`.
3. Then the test `pattern:\b` matches again, as we're between `subject:o` and a space. 3. Then the test `pattern:\b` matches again, as we're between `subject:o` and a comma.
The pattern `pattern:\bHello\b` would also match. But not `pattern:\bHell\b` (because there's no word boundary after `l`) and not `Java!\b` (because the exclamation sign is not a wordly character `pattern:\w`, so there's no word boundary after it). The pattern `pattern:\bHello\b` would also match. But not `pattern:\bHell\b` (because there's no word boundary after `l`) and not `Java!\b` (because the exclamation sign is not a wordly character `pattern:\w`, so there's no word boundary after it).