walk_to_end
The iterator is currently inside a capturing group. Walk to the close of this group, skipping over any nested groups and handling escaped parentheses correctly.
def walk_to_end(
ch: string,
input_iter: iterator
) - > null
The iterator is currently inside a capturing group. Walk to the close of this group, skipping over any nested groups and handling escaped parentheses correctly.
Parameters
| Name | Type | Description |
|---|---|---|
| ch | string | The current character being processed to determine the initial nesting level. |
| input_iter | iterator | An iterator yielding tuples of (character, is_escaped) used to traverse the remaining regex pattern. |
Returns
| Type | Description |
|---|---|
null | Returns nothing; the function exits once the matching closing parenthesis for the current nesting level is found. |