Skip to content

Commit 2218e43

Browse files
committed
Add whitespaces after comma and remove redundant whitespaces.
Manage whitespaces Remove unrelated line Fix Fix again
1 parent e8a15c6 commit 2218e43

File tree

2 files changed

+21
-21
lines changed

2 files changed

+21
-21
lines changed

stdlib/public/SDK/UIKit/UIKit.swift

+14-14
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import Foundation
2121
@_transparent // @fragile
2222
@warn_unused_result
2323
public func == (lhs: UIEdgeInsets, rhs: UIEdgeInsets) -> Bool {
24-
return lhs.top == rhs.top &&
24+
return lhs.top == rhs.top &&
2525
lhs.left == rhs.left &&
2626
lhs.bottom == rhs.bottom &&
2727
lhs.right == rhs.right
@@ -32,7 +32,7 @@ extension UIEdgeInsets : Equatable {}
3232
@_transparent // @fragile
3333
@warn_unused_result
3434
public func == (lhs: UIOffset, rhs: UIOffset) -> Bool {
35-
return lhs.horizontal == rhs.horizontal &&
35+
return lhs.horizontal == rhs.horizontal &&
3636
lhs.vertical == rhs.vertical
3737
}
3838

@@ -46,16 +46,16 @@ extension UIOffset : Equatable {}
4646

4747
#if !os(watchOS) && !os(tvOS)
4848
public extension UIDeviceOrientation {
49-
var isLandscape: Bool {
50-
get { return self == .LandscapeLeft || self == .LandscapeRight }
49+
var isLandscape: Bool {
50+
get { return self == .LandscapeLeft || self == .LandscapeRight }
5151
}
5252

53-
var isPortrait: Bool {
54-
get { return self == .Portrait || self == .PortraitUpsideDown }
53+
var isPortrait: Bool {
54+
get { return self == .Portrait || self == .PortraitUpsideDown }
5555
}
5656

5757
var isFlat: Bool {
58-
get { return self == .FaceUp || self == .FaceDown }
58+
get { return self == .FaceUp || self == .FaceDown }
5959
}
6060

6161
var isValidInterfaceOrientation: Bool {
@@ -81,7 +81,7 @@ public func UIDeviceOrientationIsLandscape(
8181
public func UIDeviceOrientationIsPortrait(
8282
orientation: UIDeviceOrientation
8383
) -> Bool {
84-
return orientation.isPortrait
84+
return orientation.isPortrait
8585
}
8686

8787
@warn_unused_result
@@ -98,12 +98,12 @@ public func UIDeviceOrientationIsValidInterfaceOrientation(
9898

9999
#if !os(watchOS) && !os(tvOS)
100100
public extension UIInterfaceOrientation {
101-
var isLandscape: Bool {
102-
get { return self == .LandscapeLeft || self == .LandscapeRight }
101+
var isLandscape: Bool {
102+
get { return self == .LandscapeLeft || self == .LandscapeRight }
103103
}
104104

105-
var isPortrait: Bool {
106-
get { return self == .Portrait || self == .PortraitUpsideDown }
105+
var isPortrait: Bool {
106+
get { return self == .Portrait || self == .PortraitUpsideDown }
107107
}
108108
}
109109

@@ -173,7 +173,7 @@ struct _UIViewMirror : _MirrorType {
173173

174174
var _v : UIView
175175

176-
init(_ v : UIView) {_v = v}
176+
init(_ v : UIView) { _v = v }
177177

178178
var value: Any { get { return _v } }
179179

@@ -187,7 +187,7 @@ struct _UIViewMirror : _MirrorType {
187187
_preconditionFailure("_MirrorType access out of bounds")
188188
}
189189

190-
var summary: String { get { return ""} }
190+
var summary: String { get { return "" } }
191191

192192
var quickLookObject: PlaygroundQuickLook? {
193193
// iOS 7 or greater only

stdlib/public/core/Optional.swift

+7-7
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ func _injectNothingIntoOptional<Wrapped>() -> Wrapped? {
138138
// Comparisons
139139
@warn_unused_result
140140
public func == <T: Equatable> (lhs: T?, rhs: T?) -> Bool {
141-
switch (lhs,rhs) {
141+
switch (lhs, rhs) {
142142
case let (l?, r?):
143143
return l == r
144144
case (nil, nil):
@@ -230,8 +230,8 @@ internal struct _OptionalMirror<Wrapped> : _MirrorType {
230230
var count: Int { return (_value != nil) ? 1 : 0 }
231231

232232
subscript(i: Int) -> (String, _MirrorType) {
233-
switch (_value,i) {
234-
case (.Some(let contents),0) : return ("Some",_reflect(contents))
233+
switch (_value, i) {
234+
case (.Some(let contents), 0) : return ("Some", _reflect(contents))
235235
default: _preconditionFailure("cannot extract this child index")
236236
}
237237
}
@@ -251,7 +251,7 @@ internal struct _OptionalMirror<Wrapped> : _MirrorType {
251251

252252
@warn_unused_result
253253
public func < <T : Comparable> (lhs: T?, rhs: T?) -> Bool {
254-
switch (lhs,rhs) {
254+
switch (lhs, rhs) {
255255
case let (l?, r?):
256256
return l < r
257257
case (nil, _?):
@@ -263,7 +263,7 @@ public func < <T : Comparable> (lhs: T?, rhs: T?) -> Bool {
263263

264264
@warn_unused_result
265265
public func > <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
266-
switch (lhs,rhs) {
266+
switch (lhs, rhs) {
267267
case let (l?, r?):
268268
return l > r
269269
default:
@@ -273,7 +273,7 @@ public func > <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
273273

274274
@warn_unused_result
275275
public func <= <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
276-
switch (lhs,rhs) {
276+
switch (lhs, rhs) {
277277
case let (l?, r?):
278278
return l <= r
279279
default:
@@ -283,7 +283,7 @@ public func <= <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
283283

284284
@warn_unused_result
285285
public func >= <T : Comparable>(lhs: T?, rhs: T?) -> Bool {
286-
switch (lhs,rhs) {
286+
switch (lhs, rhs) {
287287
case let (l?, r?):
288288
return l >= r
289289
default:

0 commit comments

Comments
 (0)