Skip to content

Commit e0e0213

Browse files
authored
Gardening: remove trailing whitespaces (#197)
1 parent 5d4c007 commit e0e0213

File tree

84 files changed

+431
-431
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+431
-431
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,6 @@ Steps to reproduce the behavior:
5555

5656
<!-- Git hash of the site if applicable -->
5757

58-
## Additional context
58+
## Additional context
5959

6060
<!-- Add any other context about the problem here. -->

_posts/2016-01-29-swift-api-transformation.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ things just look *different*, often needlessly so. This is no mere
1515
aesthetic concern; non-uniformity and lack of predictability make
1616
everything harder, from coding to debugging to maintenance.
1717
Fortunately Swift developers created tons of great code in spite of
18-
that gap, and along the way, there evolved a sense of what
18+
that gap, and along the way, there evolved a sense of what
1919
“Swifty” code looks and feels like.
2020

2121
Informed by that experience, when looking at our APIs, it's easy to
@@ -77,15 +77,15 @@ changes this call:
7777

7878
~~~swift
7979
path.addArcWithCenter(
80-
origin, radius: 20.0,
80+
origin, radius: 20.0,
8181
startAngle: 0.0, endAngle: CGFloat(M_PI) * 2.0, clockwise: true)
8282
~~~
8383

8484
into this:
8585

8686
~~~swift
8787
path.addArc(
88-
center: origin, radius: 20.0,
88+
center: origin, radius: 20.0,
8989
startAngle: 0.0, endAngle: CGFloat(M_PI) * 2.0, clockwise: true)
9090
~~~
9191

_posts/2016-02-01-swift-CI.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ title: Continuous Integration now Available
66
author: najacque
77
---
88

9-
We are excited to announce that we have rolled out [continuous integration]({{ site.url }}/continuous-integration) (aka, CI) for the Swift project!
9+
We are excited to announce that we have rolled out [continuous integration]({{ site.url }}/continuous-integration) (aka, CI) for the Swift project!
1010

1111
Our CI system is powered by [Jenkins](https://jenkins-ci.org). For Apple's platforms it builds and runs tests for macOS and the iOS simulator. For Linux it builds and runs tests for Ubuntu 14.04 and Ubuntu 15.10 (both for x86_64). In addition to using it for testing active branches, the CI system also produces the snapshots that are available for download from Swift.org.
1212

@@ -33,7 +33,7 @@ If there are issues found during testing, you will get a link to the details of
3333
In the near future, we will also be supporting running performance tests. We also welcome community involvement to help us expand testing to additional configurations.
3434

3535

36-
36+
3737

3838

3939

_posts/2016-05-06-swift-3.0-release-process.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ Swift 3.0 is also the first release to include the [Swift Package Manager]({{
1919
site.url }}/package-manager/). While the Swift Package Manager is still early
2020
in its development, it supports the development and distribution of
2121
cross-platform Swift packages. The Swift Package Manager will be available on
22-
both Darwin and Linux.
22+
both Darwin and Linux.
2323

2424
For Linux, Swift 3 will also be the first release to contain the [Swift Core
25-
Libraries]({{ site.url }}/core-libraries/).
25+
Libraries]({{ site.url }}/core-libraries/).
2626

2727
Swift 3.0 is expected to be released sometime in late 2016. In addition to its
2828
Swift.org release, Swift 3.0 will ship in a future version of Xcode.
@@ -84,7 +84,7 @@ Swift.org release, Swift 3.0 will ship in a future version of Xcode.
8484
- The first developer preview branch `swift-3.0-preview-1-branch` will
8585
be created from `master` on **May 12**. It will be released 4-6 weeks
8686
later.
87-
87+
8888
- The date for creating the last developer preview branch
8989
&mdash; `swift-3.0-branch` &mdash; has
9090
not yet been established. When that date is determined the plan will be

_posts/2016-06-13-swift-3.0-preview-1-released.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,6 @@ This should be resolved in a future beta.
8585
### Migrating to Swift 3
8686

8787
Swift 3 is a source-breaking release over Swift 2.2.1. It contains many syntactic refinements and improvements,
88-
but also a huge number of changes for how Objective-C APIs import into Swift due to [SE-0005](https://github.com/apple/swift-evolution/blob/master/proposals/0005-objective-c-name-translation.md).
88+
but also a huge number of changes for how Objective-C APIs import into Swift due to [SE-0005](https://github.com/apple/swift-evolution/blob/master/proposals/0005-objective-c-name-translation.md).
8989
Please consult the [migration guide]({{ site.url }}/migration-guide/) for guidance and tips
9090
for migrating to Swift 3.

_posts/2016-10-21-whole-module-optimizations.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ With whole-module optimization the compiler can do a lot better. When compiling
5656

5757
![whole-module compilation]({{ site.url }}/assets/images/wmo-blog/wmo.png)
5858

59-
This has two big advantages. First, the compiler sees the implementation of all functions in a module, so it can perform optimizations like function inlining and function specialization.
59+
This has two big advantages. First, the compiler sees the implementation of all functions in a module, so it can perform optimizations like function inlining and function specialization.
6060
Function specialization means that the compiler creates a new version of a function which is optimized for a specific call-context. For example, the compiler can specialize a generic function for concrete types.
6161

6262
In our example, the compiler produces a version of the generic `Container` which is specialized for the concrete type `Int`.
@@ -71,7 +71,7 @@ struct Container {
7171
}
7272
~~~
7373

74-
Then the compiler can inline the specialized `getElement` function into the `add` function.
74+
Then the compiler can inline the specialized `getElement` function into the `add` function.
7575

7676
~~~swift
7777
func add (c1: Container<Int>, c2: Container<Int>) -> Int {
@@ -104,7 +104,7 @@ Internally the compiler runs in multiple phases: parser, type checking, SIL opti
104104

105105
Parsing and type checking is very fast in most cases, and we expect it to get even faster in subsequent Swift releases.
106106
The SIL optimizer (SIL stands for “Swift Intermediate Language”) performs all the important Swift-specific optimizations, like generic specialization, function inlining, etc. This phase of the compiler typically takes about one third of the compilation time.
107-
Most of the compilation time is consumed by the LLVM backend which runs lower-level optimizations and does the code generation.
107+
Most of the compilation time is consumed by the LLVM backend which runs lower-level optimizations and does the code generation.
108108

109109
After performing whole-module optimizations in the SIL optimizer the module is split again into multiple parts. The LLVM backend processes the split parts in multiple threads. It also avoids re-processing of a part if that part didn’t change since the previous build.
110110
So even with whole-module optimizations, the compiler is able to perform a big part of the compilation work in parallel (multi-threaded) and incrementally.

_posts/2016-12-9-swift-3.1-release-process.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,13 @@ Please file [bug reports](https://bugs.swift.org) if you encounter cases where t
2525

2626
Previous releases of Swift have had "Developer Previews", e.g. "Preview 1", "Preview 2", etc., that represent stabilized snapshots of a Swift release as it converges. Developer previews have often been irregularly spaced apart, and have sometimes not provided enough granularity for the Swift community to try out new features or verify bug fixes in a release as it converges.
2727

28-
For Swift 3.1 there will instead be daily downloadable snapshots of the release branch. Snapshots will be produced as part of [continuous integration](https://ci.swift.org) testing. The cadence of downloadable snapshots will thus be more frequent and granular. Snapshots will be posted daily, assuming tests are passing.
28+
For Swift 3.1 there will instead be daily downloadable snapshots of the release branch. Snapshots will be produced as part of [continuous integration](https://ci.swift.org) testing. The cadence of downloadable snapshots will thus be more frequent and granular. Snapshots will be posted daily, assuming tests are passing.
2929

3030
Once Swift 3.1 is released, official final builds will also be posted in addition to the snapshots.
3131

3232
## Getting Changes into Swift 3.1
3333

34-
Swift 3.1 is intended to be limited in scope, with the desire to move focus early in 2017 to the development of Swift 4. To meet this goal, Swift 3.1 will include changes in mainline development (i.e. the `master` branch) only until January 16. After that date there will be a "bake" period in which only select, critical fixes will go into the `swift-3.1-branch` and move `master` on to Swift 4 development.
34+
Swift 3.1 is intended to be limited in scope, with the desire to move focus early in 2017 to the development of Swift 4. To meet this goal, Swift 3.1 will include changes in mainline development (i.e. the `master` branch) only until January 16. After that date there will be a "bake" period in which only select, critical fixes will go into the `swift-3.1-branch` and move `master` on to Swift 4 development.
3535

3636
### Branches
3737

_posts/2017-09-19-swift-4.0-released.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ title: Swift 4.0 Released!
66
author: tkremenek
77
---
88

9-
Swift 4 is now officially released! Swift 4 builds on the strengths of Swift 3, delivering greater robustness and stability, providing source code compatibility with Swift 3, making improvements to the standard library, and adding features like archival and serialization.
9+
Swift 4 is now officially released! Swift 4 builds on the strengths of Swift 3, delivering greater robustness and stability, providing source code compatibility with Swift 3, making improvements to the standard library, and adding features like archival and serialization.
1010

1111
You can watch a quick overview of it by watching the [WWDC 2017: What's New in Swift](https://developer.apple.com/videos/play/wwdc2017/402/) presentation, and try out some of the new features in this [playground](https://github.com/ole/whats-new-in-swift-4) put together by Ole Begemann.
1212

_posts/2017-10-04-dictionary-and-set-improvements.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ to build and transform dictionaries with these new tools.
5757
## Grouping Values by a Key
5858

5959
<img
60-
alt="Grouping groceries by their department"
60+
alt="Grouping groceries by their department"
6161
src="{{ site.url }}/assets/images/dictionary-blog/grouping.png"
6262
srcset="{{ site.url }}/assets/images/dictionary-blog/grouping_2x.png 2x"
6363
class="dictionary-blog" />
@@ -117,19 +117,19 @@ let departmentCounts = groceriesByDepartment.mapValues { items in items.count }
117117
// departmentCounts[.bakery] == 2
118118
~~~
119119

120-
Because the dictionary has all the same keys,
121-
just with different values,
122-
it can use the same internal layout as the original dictionary
123-
and doesn't need to recompute any hash values.
124-
This makes calling `mapValues(_:)` faster
120+
Because the dictionary has all the same keys,
121+
just with different values,
122+
it can use the same internal layout as the original dictionary
123+
and doesn't need to recompute any hash values.
124+
This makes calling `mapValues(_:)` faster
125125
than rebuilding the dictionary from scratch.
126126

127127
## Building Dictionaries from Key-Value Pairs
128128

129-
<img
130-
alt="Building a dictionary from names and values"
131-
src="{{ site.url }}/assets/images/dictionary-blog/uniqueKeys.png"
132-
srcset="{{ site.url }}/assets/images/dictionary-blog/uniqueKeys_2x.png 2x"
129+
<img
130+
alt="Building a dictionary from names and values"
131+
src="{{ site.url }}/assets/images/dictionary-blog/uniqueKeys.png"
132+
srcset="{{ site.url }}/assets/images/dictionary-blog/uniqueKeys_2x.png 2x"
133133
class="dictionary-blog" />
134134

135135
You can now create dictionaries
@@ -139,8 +139,8 @@ one for when you have unique keys,
139139
and one for when you might have keys that repeat.
140140

141141
If you start with a sequence of keys and a sequence of values,
142-
you can combine them
143-
into a single sequence of pairs
142+
you can combine them
143+
into a single sequence of pairs
144144
using the `zip(_:_:)` function.
145145
For example,
146146
this code creates a sequence of tuples
@@ -279,10 +279,10 @@ In addition to easier incremental changes,
279279
dictionaries now make it simpler to make changes in bulk,
280280
with methods that merge one dictionary into another.
281281

282-
<img
283-
alt="Merging two carts together"
284-
src="{{ site.url }}/assets/images/dictionary-blog/merging.png"
285-
srcset="{{ site.url }}/assets/images/dictionary-blog/merging_2x.png 2x"
282+
<img
283+
alt="Merging two carts together"
284+
src="{{ site.url }}/assets/images/dictionary-blog/merging.png"
285+
srcset="{{ site.url }}/assets/images/dictionary-blog/merging_2x.png 2x"
286286
class="dictionary-blog" />
287287

288288
To merge the contents of `cart` and another dictionary,

_posts/2017-10-17-swift-4.1-release-process.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ The vast majority of sources that built with the Swift 4.0 compiler (including t
2020

2121
## Snapshots of Swift 4.1
2222

23-
Downloadable snapshots of the Swift 4.1 release branch will be posted regularly as part of [continuous integration](https://ci.swift.org) testing.
23+
Downloadable snapshots of the Swift 4.1 release branch will be posted regularly as part of [continuous integration](https://ci.swift.org) testing.
2424

2525
Once Swift 4.1 is released the official final builds will also be posted in addition to the snapshots.
2626

_posts/2017-2-16-swift-4.0-release-process.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ A more detailed description of the intent for source compatibility for Swift rel
4343

4444
## Snapshots of Swift 4
4545

46-
As in the case of Swift 3.1, for Swift 4 there will be daily downloadable snapshots of the release branch. Snapshots will be produced as part of [continuous integration](https://ci.swift.org) testing. The cadence of downloadable snapshots will thus be more frequent and granular. Snapshots will be posted daily, assuming tests are passing.
46+
As in the case of Swift 3.1, for Swift 4 there will be daily downloadable snapshots of the release branch. Snapshots will be produced as part of [continuous integration](https://ci.swift.org) testing. The cadence of downloadable snapshots will thus be more frequent and granular. Snapshots will be posted daily, assuming tests are passing.
4747

4848
Once Swift 4 is released, official final builds will also be posted in addition to the snapshots.
4949

5050
## Getting Changes into Swift 4
5151

52-
All changes currently going into mainline development (i.e. the `master` branch) until a final branch date is announced by the release manager, which will likely be sometime in early summer of 2017. After that point there will be a "bake" period in which only select, critical fixes will go into the `swift-4.0-branch` and move `master` on to developement for the next release.
52+
All changes currently going into mainline development (i.e. the `master` branch) until a final branch date is announced by the release manager, which will likely be sometime in early summer of 2017. After that point there will be a "bake" period in which only select, critical fixes will go into the `swift-4.0-branch` and move `master` on to developement for the next release.
5353

5454
### Branches
5555

_posts/2017-3-27-swift-3.1-released.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ title: Swift 3.1 Released!
66
author: allendenison
77
---
88

9-
Swift 3.1 is now officially released! Swift 3.1 is a minor release that contains improvements and refinements to the Standard Library. Thanks to efforts by IBM and other members of the community, it also includes many updates to the Linux implementation of Swift. There are also a number of updates to Swift Package Manager.
9+
Swift 3.1 is now officially released! Swift 3.1 is a minor release that contains improvements and refinements to the Standard Library. Thanks to efforts by IBM and other members of the community, it also includes many updates to the Linux implementation of Swift. There are also a number of updates to Swift Package Manager.
1010

1111
### Language Updates
1212
Swift 3.1 is a minor language release. It is source compatible with Swift 3.0. It contains the following language changes and updates, most of which went through the Swift [Evolution process](https://swift.org/contributing/#participating-in-the-swift-evolution-process):
@@ -56,7 +56,7 @@ See more at: [SE-0147: Move UnsafeMutablePointer.initialize(from:) to UnsafeMuta
5656
* Implementation of `NSDecimal`
5757
* Implementation of `NSLengthFormatter`
5858
* Implementation of `Progress`
59-
* Many improvements to `URLSession` functionality, including API coverage and optimized usage of `libdispatch`
59+
* Many improvements to `URLSession` functionality, including API coverage and optimized usage of `libdispatch`
6060
* Improved API coverage in `NSArray`, `NSAttributedString` and many others
6161
* Significant performance improvements in `Data`. [See more details here](https://github.com/apple/swift-corelibs-foundation/blob/master/Docs/Performance%20Refinement%20of%20Data.md)
6262
* Improved JSON serialization performance

_posts/2018-01-08-conditional-conformance.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ This was possible via overloads of the `==` operator, like this one for `Array`:
4242
extension Array where Element: Equatable {
4343
public static func ==(lhs: [Element], rhs: [Element]) -> Bool {
4444
return lhs.elementsEqual(rhs)
45-
}
45+
}
4646
}
4747
~~~
4848

@@ -61,7 +61,7 @@ let a = ["1","2","x"].map(Int.init)
6161
a == [1,2,nil] // expecting 'true'
6262
~~~
6363

64-
You'd get a compiler error:
64+
You'd get a compiler error:
6565

6666
> Binary operator '==' cannot be applied to two '[Int?]' operands.
6767
@@ -189,15 +189,15 @@ start of the next subsequence in the base, or the end.
189189
extension LazySplitCollection: Collection {
190190
typealias Element = Base.SubSequence
191191
typealias Index = Base.Index
192-
192+
193193
var startIndex: Index { return base.startIndex }
194194
var endIndex: Index { return base.endIndex }
195-
195+
196196
subscript(i: Index) -> Element {
197197
let separator = base[i...].index(where: isSeparator)
198198
return base[i..<(separator ?? endIndex)]
199199
}
200-
200+
201201
func index(after i: Index) -> Index {
202202
let separator = base[i...].index(where: isSeparator)
203203
return separator.map(base.index(after:)) ?? endIndex
@@ -212,7 +212,7 @@ collection from the given index for the next separator. If there isn't one,
212212
substitute the end index in that case. The only fiddly part is skipping over
213213
the separator in the `index(after:)` implementation, which we do with an
214214
[optional map][Optional.map].
215-
215+
216216
### Extending lazy
217217

218218
Now that we have this wrapper, we want to extend all the lazy collection types

_posts/2018-01-19-forums.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Some of these categories, such as the announcement and CI Notification sub-categ
2626
In addition to categories, forum posts can also be categorized by use of tags. A forum post can have many different tags added by the poster. This is a great way to make it easy to find posts relating to certain topics, and to mark topics of interest (such as issues relating to specific projects) so that they can be easily found.
2727

2828
####Accounts
29-
Accounts can be set up using either email registration, or GitHub accounts. For those who have previously sent messages to the various Swift mailing lists, a staged account will already be set up, and you can [take control of the account](https://forums.swift.org/faq), provided you still have control of that email address.
29+
Accounts can be set up using either email registration, or GitHub accounts. For those who have previously sent messages to the various Swift mailing lists, a staged account will already be set up, and you can [take control of the account](https://forums.swift.org/faq), provided you still have control of that email address.
3030

3131
Within the forums, users can be tagged as “@Username” and can get notifications based on that tagging.
3232

@@ -37,8 +37,8 @@ You can choose to get email notifications for tracked categories tags, and can a
3737
All forum activity is expected to conform to the Swift Code of Conduct. The Code of Conduct will be prominently posted on the site. Violations can be anonymously flagged via the forum for review by administrators.
3838

3939
####FAQ
40-
Please visit the [FAQ](https://forums.swift.org/faq) for answers to common questions, procedures, and links.
41-
40+
Please visit the [FAQ](https://forums.swift.org/faq) for answers to common questions, procedures, and links.
41+
4242

4343

4444

_posts/2018-02-08-osize.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ But what about performance? This completely depends on the project. For most app
2929

3030
Let's go into the details on what the compiler does differently with `-Osize`.
3131
With `-Osize` the compiler optimizes the code, just like with `-O`.
32-
But in contrast to `-O`, the compiler tries to avoid code duplication. For example, when inlining functions the compiler uses a lower size limit to decide whether a function should be inlined.
32+
But in contrast to `-O`, the compiler tries to avoid code duplication. For example, when inlining functions the compiler uses a lower size limit to decide whether a function should be inlined.
3333

3434
Completely disabling function inlining would be a bad idea, because inlining small functions often improve code size. For example consider simple getter functions, like
3535

_posts/2018-04-26-iuo.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ For the following example, previous versions of Swift inferred the type of `labe
140140

141141
~~~swift
142142
// label is inferred to be UILabel?
143-
if let label = object.property {
143+
if let label = object.property {
144144
// Error due to passing a UILabel? where a UILabel is expected
145145
functionTakingLabel(label)
146146
}

0 commit comments

Comments
 (0)