Skip to content

Commit 808b539

Browse files
[gardening] Minor syntax cleanups.
1 parent 6cdbacc commit 808b539

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

benchmark/single-source/Phonebook.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
// for performance measuring.
1515
import TestsUtils
1616

17-
var words=[
17+
var words = [
1818
"James", "John", "Robert", "Michael", "William", "David", "Richard", "Joseph",
1919
"Charles", "Thomas", "Christopher", "Daniel", "Matthew", "Donald", "Anthony",
2020
"Paul", "Mark", "George", "Steven", "Kenneth", "Andrew", "Edward", "Brian",
@@ -27,7 +27,8 @@ var words=[
2727
"Terry", "Joe", "Sean", "Willie", "Jesse", "Ralph", "Billy", "Austin", "Bruce",
2828
"Christian", "Roy", "Bryan", "Eugene", "Louis", "Harry", "Wayne", "Ethan",
2929
"Jordan", "Russell", "Alan", "Philip", "Randy", "Juan", "Howard", "Vincent",
30-
"Bobby", "Dylan", "Johnny", "Phillip", "Craig"]
30+
"Bobby", "Dylan", "Johnny", "Phillip", "Craig"
31+
]
3132

3233
// This is a phone book record.
3334
struct Record : Comparable {

benchmark/utils/DriverUtils.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,10 @@ struct TestConfig {
102102
var tests = [Test]()
103103

104104
mutating func processArguments() -> TestAction {
105-
let validOptions=["--iter-scale", "--num-samples", "--num-iters",
106-
"--verbose", "--delim", "--run-all", "--list", "--sleep"]
105+
let validOptions = [
106+
"--iter-scale", "--num-samples", "--num-iters",
107+
"--verbose", "--delim", "--run-all", "--list", "--sleep"
108+
]
107109
let maybeBenchArgs: Arguments? = parseArgs(validOptions)
108110
if maybeBenchArgs == nil {
109111
return .Fail("Failed to parse arguments")

lib/Sema/MiscDiagnostics.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2839,7 +2839,7 @@ static void checkStmtConditionTrailingClosure(TypeChecker &TC, const Expr *E) {
28392839
if (auto TT = argsTy->getAs<TupleType>()) {
28402840
assert(TT->getNumElements() != 0 && "Unexpected empty TupleType");
28412841
auto closureLabel = TT->getElement(TT->getNumElements() - 1).getName();
2842-
if(!closureLabel.empty()) {
2842+
if (!closureLabel.empty()) {
28432843
replacement += closureLabel.str();
28442844
replacement += ": ";
28452845
}

0 commit comments

Comments
 (0)