Add code example in CompiledRegex

Signed-off-by: jorgectf <jorgectf@protonmail.com>
This commit is contained in:
jorgectf
2021-04-27 19:52:26 +02:00
parent 8a800986a2
commit 21e01b809f

View File

@@ -48,6 +48,17 @@ private module Re {
/**
* A class to find `re` methods immediately executing a compiled expression by `re.compile`.
*
* Given the following example:
*
* ```py
* pattern = re.compile(input)
* input.match(s)
* ```
*
* `patternCall` refers to `re.compile(input)`,
* `regexNode` refers to `input` and
* `this` will refer to `input.match(s)`
*
* See `RegexExecutionMethods`
*
* See https://docs.python.org/3/library/re.html#regular-expression-objects