Skip to content

Commit bf689d9

Browse files
iainsgillisziishaned
authored andcommitted
Replace braces word with parentheses (ziishaned#23)
Change wording to reflect notation in section covering lookaheads and lookbehinds: braces (i.e., ` { } `) --> parentheses (i.e., ` ( ) `)
1 parent 49960ef commit bf689d9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -341,10 +341,10 @@ by `$` character. Following are the lookarounds that are used in regular express
341341
### 4.1 Positive Lookahead
342342

343343
The positive lookahead asserts that the first part of the expression must be followed by the lookahead expression. The returned match
344-
only contains the text that is matched by the first part of the expression. To define a positive lookahead braces are used and within
345-
those braces question mark with equal sign is used like this `(?=...)`. Lookahead expression is written after the equal sign inside
346-
braces. For example, the regular expression `(T|t)he(?=\sfat)` means: optionally match lowercase letter `t` or uppercase letter `T`,
347-
followed by letter `h`, followed by letter `e`. In braces we define positive lookahead which tells regular expression engine to match
344+
only contains the text that is matched by the first part of the expression. To define a positive lookahead, parentheses are used. Within
345+
those parentheses, a question mark with equal sign is used like this: `(?=...)`. Lookahead expression is written after the equal sign inside
346+
parentheses. For example, the regular expression `(T|t)he(?=\sfat)` means: optionally match lowercase letter `t` or uppercase letter `T`,
347+
followed by letter `h`, followed by letter `e`. In parentheses we define positive lookahead which tells regular expression engine to match
348348
`The` or `the` which are followed by the word `fat`.
349349

350350
<pre>

0 commit comments

Comments
 (0)