Skip to content

Conversation

@Stevoisiak
Copy link
Contributor

@Stevoisiak Stevoisiak commented Feb 8, 2023

Update documentation for re library to explain that a backreference to group0 (\g<0>) is expanded to the entire string when using Match.expand(). Note that numeric backreferences to group 0 (\0) are not supported. (See https://stackoverflow.com/q/58134893/3357935)

Update documentation for `re` library to explain that a backreference to group0 (`\g<0>`) is expanded to the entire string when using `Match.expand()`. Note that numeric backreferences to group 0 (`\0`) are not supported. (See https://stackoverflow.com/q/58134893/3357935)
@Stevoisiak
Copy link
Contributor Author

Stevoisiak commented Feb 8, 2023

My apologies for the multiple pull requests and review tags from changing the branch. It was unintentional.

@serhiy-storchaka serhiy-storchaka enabled auto-merge (squash) February 17, 2024 08:30
@serhiy-storchaka serhiy-storchaka added needs backport to 3.11 only security fixes needs backport to 3.12 only security fixes labels Feb 17, 2024
@serhiy-storchaka serhiy-storchaka merged commit d2d7808 into python:main Feb 17, 2024
@miss-islington-app
Copy link

Thanks @Stevoisiak for the PR, and @serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Feb 17, 2024
Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

(cherry picked from commit d2d7808)

Co-authored-by: Stevoisiak <S.Vascellaro@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@bedevere-app
Copy link

bedevere-app bot commented Feb 17, 2024

GH-115583 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.12 only security fixes label Feb 17, 2024
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Feb 17, 2024
Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

(cherry picked from commit d2d7808)

Co-authored-by: Stevoisiak <S.Vascellaro@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@bedevere-app
Copy link

bedevere-app bot commented Feb 17, 2024

GH-115584 is a backport of this pull request to the 3.11 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.11 only security fixes label Feb 17, 2024
serhiy-storchaka added a commit that referenced this pull request Feb 17, 2024
…H-115584)

Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

(cherry picked from commit d2d7808)

Co-authored-by: Stevoisiak <S.Vascellaro@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
serhiy-storchaka added a commit that referenced this pull request Feb 17, 2024
…H-115583)

Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

(cherry picked from commit d2d7808)

Co-authored-by: Stevoisiak <S.Vascellaro@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
woodruffw pushed a commit to woodruffw-forks/cpython that referenced this pull request Mar 4, 2024
Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
diegorusso pushed a commit to diegorusso/cpython that referenced this pull request Apr 17, 2024
Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
LukasWoodtli pushed a commit to LukasWoodtli/cpython that referenced this pull request Jan 22, 2025
Update documentation for re library to explain that a backreference `\g<0>` is
expanded to the entire string when using Match.expand().
Note that numeric backreferences to group 0 (`\0`) are not supported.

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip news topic-regex

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants