Skip to content

Commit e29398d

Browse files
committed
Merge pull request #388 from wxxsw/whitespaces
Erase redundant whitespaces.
2 parents 447c986 + 7ac02d5 commit e29398d

21 files changed

+24
-24
lines changed

include/swift/Basic/JSONSerialization.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ struct missingTraits : public std::integral_constant<bool,
284284
&& !has_ScalarBitSetTraits<T>::value
285285
&& !has_ScalarTraits<T>::value
286286
&& !has_ObjectTraits<T>::value
287-
&& !has_ArrayTraits<T>::value> {};
287+
&& !has_ArrayTraits<T>::value> {};
288288

289289
template<typename T>
290290
struct validatedObjectTraits : public std::integral_constant<bool,

include/swift/Driver/Types.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ namespace llvm {
7575
}
7676

7777
template <typename Fn>
78-
void swift::driver::types::forAllTypes(const Fn &fn) {
78+
void swift::driver::types::forAllTypes(const Fn &fn) {
7979
static_assert(std::is_constructible<std::function<void(types::ID)>,Fn>::value,
8080
"must have the signature 'void(types::ID)'");
8181
for (uint8_t i = 0; i < static_cast<uint8_t>(TY_INVALID); ++i)

include/swift/SIL/PatternMatch.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -691,7 +691,7 @@ using BuiltinApplyTy = typename Apply_match<BuiltinValueKind, Tys...>::Ty;
691691
/// Matcher for any of the builtin checked conversions.
692692
template <typename T0>
693693
inline typename OneOf_match<BuiltinApplyTy<T0>, BuiltinApplyTy<T0>>::Ty
694-
m_CheckedConversion(const T0 &Op0) {
694+
m_CheckedConversion(const T0 &Op0) {
695695
return m_USCheckedConversion(Op0) || m_SUCheckedConversion(Op0);
696696
}
697697

include/swift/SILAnalysis/BottomUpIPAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ class BottomUpIPAnalysis : public SILAnalysis {
148148
};
149149

150150
/// Computes and stores a bottom-up function order.
151-
template<typename FunctionInfo> class BottomUpFunctionOrder {
151+
template<typename FunctionInfo> class BottomUpFunctionOrder {
152152

153153
typedef llvm::SmallVector<FunctionInfo *, 8> FunctionInfoList;
154154

lib/AST/Module.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ class SourceFile::LookupCache {
119119
Members.shrink_and_clear();
120120
}
121121

122-
decltype(Members)::const_iterator begin() const { return Members.begin(); }
122+
decltype(Members)::const_iterator begin() const { return Members.begin(); }
123123
decltype(Members)::const_iterator end() const { return Members.end(); }
124124
decltype(Members)::const_iterator find(DeclName Name) const {
125125
return Members.find(Name);
@@ -1530,7 +1530,7 @@ bool SourceFile::walk(ASTWalker &walker) {
15301530
return false;
15311531
}
15321532

1533-
StringRef SourceFile::getFilename() const {
1533+
StringRef SourceFile::getFilename() const {
15341534
if (BufferID == -1)
15351535
return "";
15361536
SourceManager &SM = getASTContext().SourceMgr;

lib/IDE/SyntaxModel.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -666,7 +666,7 @@ std::pair<bool, Stmt *> ModelASTWalker::walkToStmtPre(Stmt *S) {
666666
TokLen = 7; // '#elseif'
667667
if (!passNonTokenNode({SyntaxNodeKind::BuildConfigKeyword,
668668
CharSourceRange(Clause.Loc, TokLen) }))
669-
return { false, nullptr };
669+
return { false, nullptr };
670670

671671
if (Clause.Cond && !annotateIfConfigConditionIdentifiers(Clause.Cond))
672672
return { false, nullptr };

lib/Sema/CSRanking.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1252,7 +1252,7 @@ ConstraintSystem::findBestSolution(SmallVectorImpl<Solution> &viable,
12521252
return None;
12531253
}
12541254

1255-
SolutionDiff::SolutionDiff(ArrayRef<Solution> solutions) {
1255+
SolutionDiff::SolutionDiff(ArrayRef<Solution> solutions) {
12561256
if (solutions.size() <= 1)
12571257
return;
12581258

lib/Sema/TypeCheckAttr.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ class AttributeEarlyChecker : public AttributeVisitor<AttributeEarlyChecker> {
9595
void visitTransparentAttr(TransparentAttr *attr);
9696
void visitMutationAttr(DeclAttribute *attr);
9797
void visitMutatingAttr(MutatingAttr *attr) { visitMutationAttr(attr); }
98-
void visitNonMutatingAttr(NonMutatingAttr *attr) { visitMutationAttr(attr); }
98+
void visitNonMutatingAttr(NonMutatingAttr *attr) { visitMutationAttr(attr); }
9999
void visitDynamicAttr(DynamicAttr *attr);
100100

101101
void visitOwnershipAttr(OwnershipAttr *attr) {

stdlib/public/core/ArrayBuffer.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ extension _ArrayBuffer {
175175
element is Element,
176176
"Down-casted Array element failed to match the target type")
177177
}
178-
else {
178+
else {
179179
let ns = _nonNative
180180
_precondition(
181181
ns.objectAtIndex(index) is Element,

stdlib/public/core/String.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ extension String : _BuiltinUTF16StringLiteralConvertible {
208208
public init(
209209
_builtinUTF16StringLiteral start: Builtin.RawPointer,
210210
numberOfCodeUnits: Builtin.Word
211-
) {
211+
) {
212212
self = String(
213213
_StringCore(
214214
baseAddress: COpaquePointer(start),

test/1_stdlib/Mirror.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func find(substring: String, within domain: String) -> String.Index? {
5555
if (domainCount < substringCount) { return nil }
5656
var sliceStart = domain.startIndex
5757
var sliceEnd = domain.startIndex.advancedBy(substringCount)
58-
for var i = 0;; ++i {
58+
for var i = 0;; ++i {
5959
if domain[sliceStart..<sliceEnd] == substring {
6060
return sliceStart
6161
}

test/Constraints/generic_overload.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ var f2_x1_x1b = f2(x1, x1b)
4444
i = f2_x1_x1b
4545

4646
// Overloading of struct methods
47-
struct StructOverload<U> {
47+
struct StructOverload<U> {
4848
func f0<T : P1>(u: U, t: T) -> Int { return 0 }
4949
func f0<T : P2>(u: U, t: T) -> Double { return 0 }
5050

@@ -65,7 +65,7 @@ var so_f1_x2 = SO.f1(5, t: x2)
6565
d = so_f1_x2
6666

6767
// Overloading of class methods
68-
class ClassOverloadA<U> {
68+
class ClassOverloadA<U> {
6969
func f0<T : P1>(u: U, t: T) -> Int { return 0 }
7070
func f1<T : P2>(u: U, t: T) -> Double { return 0 }
7171
}

test/IRGen/class_bounded_generics.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,6 @@ func class_bounded_metatype<T: SomeSwiftClass>(t : T) {
257257
t.dynamicType.foo()
258258
}
259259

260-
class WeakRef<T: AnyObject> {
260+
class WeakRef<T: AnyObject> {
261261
weak var value: T?
262262
}

test/Interpreter/generics.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ func checkOverloadResolution() {
9393
}
9494
checkOverloadResolution()
9595

96-
class Base {
96+
class Base {
9797
var v = 0
9898
required init() {}
9999
func map() {

test/Prototypes/FloatingPoint.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -770,7 +770,7 @@ extension BinaryFloatingPointType {
770770
}
771771

772772
public static func sqrt<X: BinaryFloatingPointType>(x: X) -> Self {
773-
if X._fractionalBitCount <= Self._fractionalBitCount { return sqrt(Self(x)) }
773+
if X._fractionalBitCount <= Self._fractionalBitCount { return sqrt(Self(x)) }
774774
return Self(X._sqrtStickyRounding(x))
775775
}
776776

test/Prototypes/Integers.swift.gyb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ public typealias UWord = UInt${word_bits}
168168

169169
public protocol IntegerType
170170
: Comparable, ArithmeticType,
171-
IntegerLiteralConvertible, CustomStringConvertible {
171+
IntegerLiteralConvertible, CustomStringConvertible {
172172

173173
// Dispatching through these puts less stress on the user reading
174174
// the interface and error messages (and on the type checker) than

test/SILGen/let_decls.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ func testGetOnlySubscript(x : GetOnlySubscriptStruct, idx : Int) -> Int {
152152
extension Optional {
153153
func getLV() -> Int { }
154154
}
155-
struct CloseOverAddressOnlyConstant<T> {
155+
struct CloseOverAddressOnlyConstant<T> {
156156
func isError() {
157157
let AOV = Optional<T>()
158158
takeClosure({ AOV.getLV() })

test/SILPasses/copyforward.sil

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ sil @f_in_guaranteed : $@convention(thin) <T> (@in_guaranteed T) -> ()
1111
sil @f_out : $@convention(thin) <T> (@out T) -> ()
1212
sil @f_owned : $@convention(thin) <T> (@owned T) -> ()
1313

14-
protocol P {
14+
protocol P {
1515
init(_ i : Int32)
1616
};
1717

test/SILPasses/definite_init_diagnostics.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ class ClassWhoseInitDoesntReturn : BaseWithConvenienceInits {
721721
}
722722

723723
// <rdar://problem/17233681> DI: Incorrectly diagnostic in delegating init with generic enum
724-
enum r17233681Lazy<T> {
724+
enum r17233681Lazy<T> {
725725
case Thunk(() -> T)
726726
case Value(T)
727727

test/SILPasses/devirt_static_witness_method.sil

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import Builtin
55
import Swift
66
import SwiftShims
77

8-
protocol CanAdd {
8+
protocol CanAdd {
99
func +(lhs: Self, rhs: Self) -> Self
1010
}
1111

test/Sema/availability_versions.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -757,7 +757,7 @@ class ClassWithDeclarationsOfUnavailableClasses {
757757
func unavailableMethodWithUnavailableParameterType(o : ClassAvailableOn10_10) {
758758
}
759759

760-
func methodWithUnavailableReturnType() -> ClassAvailableOn10_10 { // expected-error {{'ClassAvailableOn10_10' is only available on OS X 10.10 or newer}}
760+
func methodWithUnavailableReturnType() -> ClassAvailableOn10_10 { // expected-error {{'ClassAvailableOn10_10' is only available on OS X 10.10 or newer}}
761761
// expected-note@-1 {{add @available attribute to enclosing class}}
762762
// expected-note@-2 {{add @available attribute to enclosing instance method}}
763763

@@ -768,7 +768,7 @@ class ClassWithDeclarationsOfUnavailableClasses {
768768
}
769769

770770
@available(OSX, introduced=10.10)
771-
func unavailableMethodWithUnavailableReturnType() -> ClassAvailableOn10_10 {
771+
func unavailableMethodWithUnavailableReturnType() -> ClassAvailableOn10_10 {
772772
return ClassAvailableOn10_10()
773773
}
774774

0 commit comments

Comments
 (0)