Skip to content

Commit 1c96658

Browse files
authored
Merge pull request #5 from trill-lang/nits
Cleanup
2 parents aceb282 + 5ed1849 commit 1c96658

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

Sources/FileCheck/CheckString.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ private func diagnoseFailedCheck(
329329
} else {
330330
diagnose(.error,
331331
at: loc,
332-
with: prefix + ": could not find '\(pattern.fixedString)' in input",
332+
with: prefix + ": could not find match for CHECK line",
333333
options: options
334334
)
335335
}

Sources/FileCheck/EditDistance.swift

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,11 @@
22
///
33
/// - parameter fa: The first sequence to compare.
44
/// - parameter ta: The second sequence to compare.
5-
/// - parameter allowReplacements: Whether to allow element replacements (change one
6-
/// element into another) as a single operation, rather than as two operations
7-
/// (an insertion and a removal).
8-
/// - parameter maxEditDistance: If non-zero, the maximum edit distance that this
9-
/// routine is allowed to compute. If the edit distance will exceed that
10-
/// maximum, returns \c MaxEditDistance+1.
115
///
12-
/// - returns: the minimum number of element insertions, removals, or (if
13-
/// `allowReplacements` is `true`) replacements needed to transform one of
14-
/// the given sequences into the other. If zero, the sequences are identical.
15-
func editDistance(from fa : Substring, to ta : Substring, allowReplacements : Bool = true, maxEditDistance : Int = 0) -> Int {
6+
/// - returns: the minimum number of element insertions, removals, or
7+
/// replacements needed to transform one of the given sequences into the
8+
/// other. If zero, the sequences are identical.
9+
func editDistance(from fa : Substring, to ta : Substring) -> Int {
1610
guard !fa.isEmpty else {
1711
return ta.count
1812
}

0 commit comments

Comments
 (0)