Skip to content

[DO NOT MERGE] main -> 5.7 diffs #362

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 160 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
160 commits
Select commit Hold shift + click to select a range
381a3c7
Add DelimiterSyntax.md
hamishknight Mar 18, 2022
c79f457
Expand on parsing issues with `/` as delimited. Add a note about edit…
DaveEwing Mar 20, 2022
731292e
Rewrite that Editor Considerations paragraph.
DaveEwing Mar 21, 2022
1049276
Change single quote constructs to be invalid
hamishknight Mar 21, 2022
c7d556c
Elaborate on starting character limitations
hamishknight Mar 21, 2022
7074cfb
Elaborate on comma case
hamishknight Mar 21, 2022
945219e
grammar
hamishknight Mar 21, 2022
d1d0d57
Add comma disambiguation
hamishknight Mar 21, 2022
bcebfc6
Update comma disambiguation
hamishknight Mar 21, 2022
1c2b7ad
Flip pitch to `/.../` as the main syntax
hamishknight Mar 22, 2022
e841184
Update alternatives considered
hamishknight Mar 23, 2022
be7a802
Fix headings
hamishknight Mar 23, 2022
06c2b28
Tweak phrasing
hamishknight Mar 23, 2022
91a93a8
Small tweaks
hamishknight Mar 23, 2022
c0e3bef
Tweak
hamishknight Mar 23, 2022
298092c
Flesh things out a bit more. Initial bits for the Intro and Motivatio…
DaveEwing Mar 24, 2022
1ebefa1
Expand out disclosure triangles, and other tweaks
hamishknight Mar 24, 2022
811bfcb
Generalize discussion on language mode
hamishknight Mar 24, 2022
70be006
Expand some prose
hamishknight Mar 25, 2022
4bb25b3
Update to also pitch `#/.../#`
hamishknight Mar 28, 2022
35d9132
Add DSL example
hamishknight Mar 28, 2022
f99dadb
Rejig motivation/solution
hamishknight Mar 29, 2022
eed1b24
Expand on typed captures
hamishknight Mar 29, 2022
7ad4037
Generalize language mode
hamishknight Mar 29, 2022
f4ef0c2
Add multi-line mode
hamishknight Mar 31, 2022
b25a0b8
Remove Normalization and Grapheme data for SPI
Azoy Mar 31, 2022
addfbfd
Update pitch
hamishknight Apr 1, 2022
bb819f6
Clarify upgrade path
hamishknight Apr 1, 2022
36f7160
Remove AST CustomCharacterClass consumer generation
hamishknight Apr 4, 2022
ed9f72c
Convert scalar escape sequences to DSL scalars
hamishknight Apr 4, 2022
afcc40b
Update proposals (#248)
milseman Apr 4, 2022
d56d706
Update status link (#249)
milseman Apr 4, 2022
d57107b
Update DSL proposal.
rxwei Apr 5, 2022
c8c2001
Merge pull request #250 from rxwei/dsl-update
rxwei Apr 5, 2022
5ec5001
Complete list of authors
rxwei Apr 5, 2022
38aedc0
Merge pull request #251 from rxwei/dsl-update
rxwei Apr 5, 2022
b78d7d0
Add `Regex<Match, Captures>` alternative to regex proposal
rxwei Apr 5, 2022
1310985
Merge pull request #252 from rxwei/dsl-update
rxwei Apr 5, 2022
45e8a1f
Fix HexDigit definition in RegexSyntax.md
hamishknight Apr 5, 2022
189d329
Merge pull request #253 from hamishknight/fix-hex-syntax
hamishknight Apr 5, 2022
ebfcdb3
Merge pull request #240 from Azoy/spi-unicode
Azoy Apr 5, 2022
0a9447a
Update typed captures section + other tweaks
hamishknight Apr 6, 2022
5d4d136
Merge pull request #245 from hamishknight/to-scale
hamishknight Apr 7, 2022
52bc932
Clean up based on the String Processing Algorithms proposal (#247)
itingliu Apr 7, 2022
3b77fe4
Fill out remainder of options API (#246)
natecook1000 Apr 7, 2022
93abfcb
Move `CharacterClass` API into RegexBuilder (#254)
natecook1000 Apr 8, 2022
b41edbd
Author links
hamishknight Apr 8, 2022
0c2ed87
Update regex syntax pitch (#258)
milseman Apr 8, 2022
e0cea6c
Typo (#259)
milseman Apr 8, 2022
2e80ced
Proposal cleanup (#260)
milseman Apr 8, 2022
c5db717
Update ProposalOverview.md
milseman Apr 8, 2022
8da68d3
Updated extended delimiter section
hamishknight Apr 8, 2022
5af9ca5
Eliminate extra public API (#256)
natecook1000 Apr 8, 2022
9d0cf04
Update delimiter proposal
milseman Apr 9, 2022
fed4c53
Throwing customization hooks (#261)
milseman Apr 10, 2022
720c10c
Update Documentation/Evolution/DelimiterSyntax.md
hamishknight Apr 11, 2022
c045e21
Clarify backslash rule
hamishknight Apr 11, 2022
ff6b443
Remove docc-plugin dependency (#263)
natecook1000 Apr 11, 2022
969bd91
Added a Trying it out section
milseman Apr 11, 2022
e31262d
Minor tweaks
hamishknight Apr 11, 2022
0454f13
Allow custom character classes to begin with `:`
hamishknight Apr 12, 2022
19adde4
Merge pull request #269 from hamishknight/posixbly
hamishknight Apr 12, 2022
bf7702f
Update pitch
hamishknight Apr 12, 2022
9c8a116
Rename DelimiterSyntax.md -> RegexLiterals.md
hamishknight Apr 12, 2022
ce458eb
Nominalize API names (#271)
milseman Apr 12, 2022
657c4a6
Allow POSIX character properties outside of custom character classes
hamishknight Apr 13, 2022
0338178
Merge pull request #187 from hamishknight/delimiter-syntax
hamishknight Apr 13, 2022
81ce4ef
Update RegexLiterals.md
hamishknight Apr 13, 2022
fad4dd9
Merge pull request #272 from hamishknight/posix-quirks
hamishknight Apr 13, 2022
39cb22d
Merge pull request #274 from hamishknight/tweak-regex-literal-pitch
hamishknight Apr 13, 2022
859c3d5
Update RegexLiterals.md
hamishknight Apr 14, 2022
935d748
Merge pull request #277 from hamishknight/tweak-regex-literal-pitch
hamishknight Apr 14, 2022
33b0b4c
Fix character class trivia matching
hamishknight Apr 14, 2022
70ecb27
Fix trivia parsing for set operations and initial `]` cases
hamishknight Apr 14, 2022
63ab0a9
Merge pull request #278 from hamishknight/trivagone
hamishknight Apr 14, 2022
a487e94
Add SwiftStdlib 5.7 availability (#276)
rxwei Apr 14, 2022
6f7ab96
Throw error if we encounter stray opening '('
hamishknight Apr 14, 2022
aede1f7
Change matching option scoping behavior to match PCRE
hamishknight Apr 14, 2022
4428e7f
Move RegexComponent conformances to RegexBuilder (#279)
natecook1000 Apr 14, 2022
34da2b6
Merge pull request #237 from hamishknight/mix-n-match
hamishknight Apr 14, 2022
89da9f8
Error on unknown character properties
hamishknight Apr 14, 2022
da89bf7
Rename RegexComponent.Output (#281)
natecook1000 Apr 14, 2022
b3b8fee
Add remaining availability annotations.
rxwei Apr 15, 2022
a0ed7e1
Merge pull request #283 from rxwei/fix-availability
rxwei Apr 15, 2022
dfec8fb
Import _RegexParser as implementation only
rxwei Apr 15, 2022
59ad177
Merge pull request #287 from apple/impl-import
rxwei Apr 15, 2022
3293905
Fix release build.
rxwei Apr 16, 2022
c6cdf6c
Throwing matches and update to CustomMatchingRegexComponent
itingliu Apr 13, 2022
15a20b2
Merge pull request #292 from rxwei/fix-288
rxwei Apr 16, 2022
a342405
Add Substring algorithms tests (#289)
natecook1000 Apr 18, 2022
b959d0a
Merge pull request #273 from itingliu/throwing-hooks
rxwei Apr 18, 2022
fea6fe2
RegexBuilder quantifiers take an optional behavior (#293)
natecook1000 Apr 18, 2022
42641da
Nominalize option methods (#295)
natecook1000 Apr 18, 2022
e1604a6
Merge pull request #280 from hamishknight/error-on-unknown-props
hamishknight Apr 19, 2022
3f16170
Don't parse a character property containing a backslash
hamishknight Apr 19, 2022
fa5f2f1
Update Regex Syntax document for `[:...:]` changes
hamishknight Apr 19, 2022
9ccde19
Support obtaining captures by name on `AnyRegexOutput` (#300)
rxwei Apr 19, 2022
182da3b
Untangle `_RegexParser` from `RegexBuilder` (#299)
natecook1000 Apr 19, 2022
8068ea1
Merge pull request #301 from hamishknight/yet-more-posix-quirks
hamishknight Apr 19, 2022
08b7808
Merge pull request #302 from hamishknight/update-syntax
hamishknight Apr 19, 2022
00aa315
Expose `matches`, `ranges` and `split` (#304)
itingliu Apr 19, 2022
15355bf
Convenience quoting (#305)
milseman Apr 19, 2022
46b9a0f
Remove compiling argument label (#306)
milseman Apr 20, 2022
b24d3ea
Move the closure argument to the end of the arg list (#307)
itingliu Apr 21, 2022
f9a4675
Adds RegexBuilder.CharacterClass.anyUnicodeScalar (#315)
natecook1000 Apr 21, 2022
4857bc7
Allow setting any of the three quant behaviors (#311)
natecook1000 Apr 21, 2022
73a5ccf
Add `wholeMatch` and `prefixMatch` (#286)
itingliu Apr 22, 2022
3e2160c
Update local proposal copies (#317)
milseman Apr 22, 2022
53acbb2
Update ProposalOverview.md
milseman Apr 22, 2022
b057c4e
Update ProposalOverview.md
milseman Apr 22, 2022
8dd8470
Unicode for String Processing proposal (#257)
natecook1000 Apr 22, 2022
81bc5d0
Updates for algorithms proposal (#319)
milseman Apr 22, 2022
89b80bf
Preparation for location aware diagnostics in the compiler.
rintaro Apr 11, 2022
06f40f6
Merge pull request #321 from rintaro/diagnostic-swiftcompiler
rintaro Apr 22, 2022
1f99047
Rename CustomPrefixMatchRegexComponent to CustomConsumingRegexCompone…
itingliu Apr 22, 2022
563d6c2
Remove String.Index evils
Azoy Apr 23, 2022
70c0756
Merge pull request #331 from Azoy/remove-string-index-init
Azoy Apr 23, 2022
571e259
More updates for algorithms proposal (#324)
natecook1000 Apr 23, 2022
2df0f24
Add ~= overloads (#335)
milseman Apr 23, 2022
dfa4ea1
Fix a missed type name change
natecook1000 Apr 23, 2022
6fab471
Add a default arity and an flag for silencing logs
natecook1000 Apr 23, 2022
7b737e3
Add `@RegexComponentBuilder` overloads for string processing algorith…
itingliu Apr 24, 2022
c56dc76
Remove @testable annotations where possible
natecook1000 Apr 22, 2022
59a34cb
Switch FixedPatternConsumer to be over Sequence
natecook1000 Apr 23, 2022
caad657
Update Sequence/Collection constraints
natecook1000 Apr 23, 2022
b7a021f
Update trim(while:) - rethrowing and nonescaping
natecook1000 Apr 23, 2022
e0b4d5e
Add tests for trim methods
natecook1000 Apr 23, 2022
d6a01e7
Add maxSplits and omitEmpty to split methods
natecook1000 Apr 23, 2022
e81a8bd
Add tests / fixes for contains / firstRange(of:)
natecook1000 Apr 23, 2022
9e09bf8
Test to ensure stdlib `split` is still accessible
natecook1000 Apr 24, 2022
433740b
Fix stale links
milseman Apr 25, 2022
8dce8c2
Mention API naming consistency (#341)
milseman Apr 25, 2022
1fd5115
Generic `~=` operator
rxwei Apr 23, 2022
5af1427
Add `@RegexComponentBuilder` overloads for collection algorithms (#342)
itingliu Apr 25, 2022
882c2be
Merge pull request #339 from rxwei/generic-pattern-matching-operator
rxwei Apr 25, 2022
ab308ee
Revise doc comments for API reference style.
amartini51 Apr 21, 2022
1467470
Algorithm cleanup (#351)
milseman Apr 26, 2022
e0922ec
API stubs for casting and named captures (#349)
milseman Apr 26, 2022
bef2092
Mention language level pattern matching (#354)
milseman Apr 26, 2022
9ff87db
Fix empty.split w/ empty separator (#353)
natecook1000 Apr 26, 2022
2401a58
Add a section describing 'find empty' behavior (#352)
natecook1000 Apr 26, 2022
d0598b7
Add example from RegexBuilder proposal as a test (#344)
natecook1000 Apr 26, 2022
435090d
Refactor generator script (#356)
milseman Apr 26, 2022
96df14d
Fix cut-off sentence.
amartini51 Apr 26, 2022
12ef33b
Update PatternConverter
Azoy Apr 26, 2022
0e59bdf
Update Sources/_StringProcessing/Regex/Match.swift
milseman Apr 27, 2022
ac618f6
Back out an accidental source change.
amartini51 Apr 27, 2022
6c5c082
Merge pull request #350 from apple/amartini/docs_91301229
amartini51 Apr 27, 2022
7d03a1e
Introduce new compiler interface
hamishknight Apr 27, 2022
b7a03c9
Merge pull request #364 from hamishknight/compiler-interface
hamishknight Apr 28, 2022
2c386ef
Add some comments
Azoy Apr 28, 2022
40c177f
Merge pull request #359 from Azoy/update-patternconverter
Azoy Apr 28, 2022
b7fb965
Replace opaque results with generic parameters in Algorithms.swift (#…
hamishknight Apr 28, 2022
838bdfe
Simplify capture representations (#360)
milseman Apr 28, 2022
e748aea
Add NegativeLookahead and Anchor comments (#372)
natecook1000 May 2, 2022
13342eb
Add matching support for `\p{Lc}`
hamishknight May 3, 2022
925f51b
Add parser support for `\p{L&}`
hamishknight May 3, 2022
ade8f01
Merge pull request #373 from hamishknight/case-in-prop
hamishknight May 3, 2022
c44efeb
Update ProposalOverview.md
milseman May 3, 2022
9801855
Add tests for AnyRegexOutput (#371)
milseman May 3, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
.DS_Store

# The current toolchain is dumping files in the package root, rude
*.emit-module.*

# Xcode
#
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
Expand Down
503 changes: 0 additions & 503 deletions Documentation/Evolution/CharacterClasses.md

This file was deleted.

56 changes: 56 additions & 0 deletions Documentation/Evolution/ProposalOverview.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@

# Regex Proposals

## Regex Type and Overview

- [Second review](https://forums.swift.org/t/se-0350-second-review-regex-type-and-overview/56886)
- [Proposal](https://github.com/apple/swift-evolution/blob/main/proposals/0350-regex-type-overview.md), [Thread](https://forums.swift.org/t/se-0350-regex-type-and-overview/56530)
- [Pitch thread](https://forums.swift.org/t/pitch-regex-type-and-overview/56029)

Presents basic Regex type and gives an overview of how everything fits into the overall story


## Regex Builder DSL

- [Proposal](https://github.com/apple/swift-evolution/blob/main/proposals/0351-regex-builder.md), [Thread](https://forums.swift.org/t/se-0351-regex-builder-dsl/56531)
- [Pitch thread](https://forums.swift.org/t/pitch-regex-builder-dsl/56007)

Covers the result builder approach and basic API.


## Run-time Regex Construction

- [Pitch](https://github.com/apple/swift-experimental-string-processing/blob/main/Documentation/Evolution/RegexSyntaxRunTimeConstruction.md), [Thread](https://forums.swift.org/t/pitch-2-regex-syntax-and-run-time-construction/56624)
- (old) Pitch thread: [Regex Syntax](https://forums.swift.org/t/pitch-regex-syntax/55711)
+ Brief: Syntactic superset of PCRE2, Oniguruma, ICU, UTS\#18, etc.

Covers the "interior" syntax, extended syntaxes, run-time construction of a regex from a string, and details of `AnyRegexOutput`.

## Regex Literals

- [Draft](https://github.com/apple/swift-experimental-string-processing/pull/187), [Thread](https://forums.swift.org/t/pitch-2-regex-literals/56736)
- (Old) original pitch:
+ [Thread](https://forums.swift.org/t/pitch-regular-expression-literals/52820)
+ [Update](https://forums.swift.org/t/pitch-regular-expression-literals/52820/90)


## String processing algorithms

- [Pitch thread](https://forums.swift.org/t/pitch-regex-powered-string-processing-algorithms/55969)

Proposes a slew of Regex-powered algorithms.

Introduces `CustomConsumingRegexComponent`, which is a monadic-parser style interface for external parsers to be used as components of a regex.

## Unicode for String Processing

- [Draft](https://github.com/apple/swift-experimental-string-processing/blob/main/Documentation/Evolution/UnicodeForStringProcessing.md)
- (Old) [Character class definitions](https://forums.swift.org/t/pitch-character-classes-for-string-processing/52920)

Covers three topics:

- Proposes regex syntax and `RegexBuilder` API for options that affect matching behavior.
- Proposes regex syntax and `RegexBuilder` API for library-defined character classes, Unicode properties, and custom character classes.
- Defines how Unicode scalar-based classes are extended to grapheme clusters in the different semantic and other matching modes.


Loading