Repository navigation
Conversation
This was referenced Oct 23, 2026
Merged
mathiasrw
marked this pull request as draft
October 23, 2026 13:17
mathiasrw
marked this pull request as ready for review
October 23, 2026 13:19
mathiasrw
added this pull request to stack #841
October 23, 2026 13:56
mathiasrw
marked this pull request as draft
October 23, 2026 15:38
mathiasrw
marked this pull request as ready for review
October 23, 2026 15:42
mathiasrw
removed this pull request from stack #841
October 23, 2026 15:57
mathiasrw
added this pull request to stack #849
October 23, 2026 16:12
mathiasrw
removed this pull request from stack #849
October 23, 2026 16:12
mathiasrw
added this pull request to stack #850
October 23, 2026 16:17
mathiasrw
removed this pull request from stack #850
October 23, 2026 16:47
mathiasrw
added this pull request to stack #853
October 23, 2026 16:51
…uppercase, with a non-ASCII digit, and rr_rr_year
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #816
Stacked on #832.
Change
The names of named groups were only found when they were ASCII (
[A-Za-z_$][\w$]*). So with(?<año>\d)andrr_añoin the code, RexReplace did not see that the code uses a group, ran it once per file where the groups are not there, and it failed withReferenceError.Now a name is found with the same rule as a name in javascript:
\p{ID_Start}and\p{ID_Continue}.The panic for a name that ends with
_(#825) works for these names too.Tests
test/fix/816.test.jsis new, and fails without the fix.yarn test-cipasses.From the review of 23 October.
After the review of 24 October
\(?<a_>bor[(?<a_>], is not one, and is no longer a panic (from the review of Access named groups from --js code to close #825 #832). It also works for any name javascript allows.rr_year_on its own is now seen as a use of the group. Before,rr_year_ + "|"gaveReferenceError: rr_year_ is not defined, an old bug from Give --js code the named groups to close #799 #806 on the same line.Follow-up
test/fix/816.test.jsalso shows the code for the odd names:rr_año_(the space cousin),rr_𝒜(outside the BMP, the reason for theuflag),rr_$é,rr_Æbleandrr_x٣, and thatrr_rr_yearis not the groupyear. 10 of 11 fail without the fix.