Skip to content

Commit 28bb16d

Browse files
authored
Merge pull request #174 from BenedictSt/typo1
Fixed some typos
2 parents 63911c4 + a91e4ca commit 28bb16d

File tree

8 files changed

+14
-14
lines changed

8 files changed

+14
-14
lines changed

Documentation/Evolution/RegexLiteralPitch.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ Multi-line comments use the `/*` delimiter. As such, a regex literal starting wi
110110

111111
#### On custom infix operators using the `/` character
112112

113-
Choosing `/` as the delimiter means there will a conflict for infix operators containing `/` in cases where whitespace isn't used, for example:
113+
Choosing `/` as the delimiter means there will be a conflict for infix operators containing `/` in cases where whitespace isn't used, for example:
114114

115115
```swift
116116
x+/y/+z

Sources/Prototypes/PTCaRet/PTCaRet.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ extension PTCaRet.Formula {
400400
_ a: Formula,
401401
during b: Formula
402402
) -> Formula {
403-
// Note: More effient to implement directly
403+
// Note: More efficient to implement directly
404404
.and(
405405
.implies(b, a),
406406
.implies(.not(b), .since(.previously(.implies(b, a)), b)))
@@ -429,7 +429,7 @@ extension PTCaRet.Formula {
429429
.atFunctionBegin(.previously(a))
430430
}
431431

432-
/// `a` has held true at every occurence of `filterA` since the
432+
/// `a` has held true at every occurrence of `filterA` since the
433433
/// most recent occurrence of both `b` and `filterB`.
434434
///
435435
/// (filterA → a) S (filterB ∧ b)
@@ -441,7 +441,7 @@ extension PTCaRet.Formula {
441441
.since(.implies(filterA, a), .and(filterB, b))
442442
}
443443

444-
/// `a` has held true at every occurence of `filterA` since the
444+
/// `a` has held true at every occurrence of `filterA` since the
445445
/// most recent occurrence of both `b` and `filterB`.
446446
///
447447
/// (filterA → a) S̅ (filterB ∧ b)

Sources/_MatchingEngine/Regex/AST/Atom.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ extension AST.Atom {
113113
// an escape sequence.
114114
@frozen
115115
public enum EscapedBuiltin: Hashable {
116-
// TOOD: better doc comments
116+
// TODO: better doc comments
117117

118118
// Literal single characters
119119

Sources/_StringProcessing/Engine/MEBuilder.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ extension MEProgram.Builder {
6161

6262
extension MEProgram.Builder {
6363
// TODO: We want a better strategy for fixups, leaving
64-
// the operand in a differenet form isn't great...
64+
// the operand in a different form isn't great...
6565

6666
public init<S: Sequence>(staticElements: S) where S.Element == Input.Element {
6767
staticElements.forEach { elements.store($0) }

Sources/_StringProcessing/Legacy/RECode.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ extension RECode {
3333
/// NOP (currently unused).
3434
case nop
3535

36-
/// Denote a sucessful match. (currently used only at the end of a program).
36+
/// Denote a successful match. (currently used only at the end of a program).
3737
case accept
3838

3939
/// Consume and try to match a unit of input.
@@ -105,7 +105,7 @@ extension RECode.Instruction {
105105
return id
106106
}
107107

108-
/// Whether this instruction particpcates in matching
108+
/// Whether this instruction participates in matching
109109
var isMatching: Bool {
110110
switch self {
111111
case .accept: return true

Sources/_StringProcessing/Legacy/VirtualMachine.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ extension RECode {
9696

9797
/// Ends the current capture at the given index and applies the given
9898
/// transform if available. Returns true on success. Returns false if the
99-
/// trasnform failed.
99+
/// transform failed.
100100
mutating func endCapture(
101101
_ endIndex: String.Index, transform: CaptureTransform?
102102
) -> Bool {

Sources/_StringProcessing/PrintAsPattern.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,9 @@ extension PrettyPrinter {
121121
print(a._patternBase)
122122

123123
case .assertion:
124-
print("/* TOOD: assertions */")
124+
print("/* TODO: assertions */")
125125
case .backreference:
126-
print("/* TOOD: backreferences */")
126+
print("/* TODO: backreferences */")
127127
}
128128

129129
case .trivia:
@@ -141,7 +141,7 @@ extension PrettyPrinter {
141141

142142
case let .convertedRegexLiteral(n, _):
143143
// FIXME: This recursion coordinates with back-off
144-
// check above, so it shoud work out. Need a
144+
// check above, so it should work out. Need a
145145
// cleaner way to do this. This means the argument
146146
// label is a lie.
147147
printAsPattern(convertedFromAST: n)
@@ -315,7 +315,7 @@ extension AST.Group.Kind {
315315
var _patternBase: String {
316316
switch self {
317317
case .capture:
318-
// TODO: We probably want this to be a prperty after group
318+
// TODO: We probably want this to be a property after group
319319
return ".capture"
320320

321321
case .namedCapture(let n):

Sources/_StringProcessing/RegexDSL/DSLTree.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ extension DSLTree {
6969

7070
/// The target of AST conversion.
7171
///
72-
/// Keeps original AST around for rich syntatic and source information
72+
/// Keeps original AST around for rich syntactic and source information
7373
case convertedRegexLiteral(Node, AST.Node)
7474

7575
// MARK: - Extensibility points

0 commit comments

Comments
 (0)