Skip to content
This repository was archived by the owner on Mar 26, 2023. It is now read-only.

Commit 3266a01

Browse files
fasskoBasThomas
andauthored
Issue 163 (#531)
Co-authored-by: Bas Broek <[email protected]>
1 parent 7801b52 commit 3266a01

File tree

2 files changed

+242
-56
lines changed

2 files changed

+242
-56
lines changed

_drafts/2020-07-02-issue-163.md

Lines changed: 0 additions & 56 deletions
This file was deleted.

_posts/2020-07-02-issue-163.md

Lines changed: 242 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,242 @@
1+
---
2+
layout: post
3+
title: ! 'Issue #163'
4+
author: fassko
5+
sponsor:
6+
link: https://engineering.linecorp.com/en/
7+
heading: LINE loves Swift!
8+
body: LINE is the leading mobile messaging platform in Japan and boasts one of the largest Swift codebases in Asia. In addition to supporting Swift versions from day 1, we strongly value semantics, protocols, and strongly typed systems. Many of our members are also active in the OSS community and support both local and global meetups and peer labs. Come join us and see what Swift can do in the real world.
9+
displaylink: engineering.linecorp.com
10+
---
11+
12+
This year's WWDC was a blast. Despite what is currently happening in the world
13+
I think Apple created a small "development holiday" for all of us. I think a
14+
new online conference reached far more folks around the world than ever before.
15+
We got completely revamped [developer forums](https://developer.apple.com/forums/),
16+
as well as many community-organized side events that were not tied to any
17+
physical location, which is great.
18+
19+
This year we got great new things, especially in SwiftUI, that are driven by
20+
new cool additions to the Swift language. And much more.
21+
Now we have a full summer to explore new stuff and get ready for new Apple
22+
releases and slowly for Apple's own built silicon.
23+
24+
<!--excerpt-->
25+
26+
{% include sponsor.html %}
27+
28+
### Podcasts
29+
30+
In the latest episode of Swift Unwrapped, [Jesse](https://twitter.com/jesse_squires)
31+
and [JP](https://twitter.com/simjp) talk [about](https://spec.fm/podcasts/swift-unwrapped/fxMk4ipF)
32+
tuples.
33+
34+
In [episode 75](https://www.swiftbysundell.com/podcast/75/) of the Swift by
35+
Sundell podcast, [Dave Verwer](https://twitter.com/daveverwer) and
36+
[Sven A. Schmidt](https://twitter.com/_sa_s) join [John](https://twitter.com/johnsundell)
37+
to talk about their newly launched [Swift Package Index](https://swiftpackageindex.com/),
38+
and what the overall state of Swift's package ecosystem is. Also dependency
39+
management, composing libraries, deploying server-side Swift in production,
40+
and much more are discussed.
41+
42+
### News and community
43+
44+
In this year's WWDC 2020 Apple had two main sections of videos about the Swift
45+
language and relevant topics:
46+
47+
* [Swift in Xcode 12](https://developer.apple.com/news/?id=4nh602ih)
48+
* [Swift deep dive](https://developer.apple.com/news/?id=tjv7v7k1)
49+
50+
In addition to that, [Tom Doron](https://twitter.com/tomerdoron) presented [how
51+
to use Swift on AWS Lambda with Xcode](https://developer.apple.com/videos/play/wwdc2020/10644/).
52+
53+
[Amy Tsai](https://twitter.com/mousiechika) shared awesome [sketch session notes](https://twitter.com/mousiechika/status/1275547535206166531)
54+
for the [Whats New In Swift](https://developer.apple.com/videos/play/wwdc2020/10170/)
55+
session.
56+
57+
A great project by [Federico Zanatello](https://twitter.com/zntfdr): [WWDC Notes](https://www.wwdcnotes.com/)
58+
- The TL;DW for Apple's WWDC videos. You can read session notes written by the
59+
community.
60+
61+
Apple released Xcode 12 and here are the [release notes](https://developer.apple.com/documentation/xcode-release-notes/xcode-12-beta-release-notes#Swift)
62+
of what has changed in Swift.
63+
64+
[Cory Benfield](https://twitter.com/Lukasaoz) shared that the Swift Crypto 1.1.0
65+
RC1 is [available](https://github.com/apple/swift-crypto/releases/tag/1.1.0-rc.1).
66+
It brings the new CryptoKit APIs from Apple’s WWDC20 platforms to all other
67+
Swift platforms.
68+
69+
The first release candidate of Swift for [TensorFlow v.0.10.0 is out](https://github.com/tensorflow/swift/blob/master/Installation.md#release-candidates).
70+
71+
[Bruno Rocha](https://twitter.com/rockthebruno) wrote [a blog post](https://swiftrocks.com/benefits-of-throwing-functions-try-swift-underrated-feature)
72+
about the benefits of using throwing functions.
73+
74+
[Moritz Lang](https://twitter.com/slashmodev) created [a repository](https://github.com/slashmo/awesome-swift-nio)
75+
listing all things SwiftNIO.
76+
77+
[Ole Begemann](https://twitter.com/olebegemann) wrote [a blog post](https://oleb.net/2020/as/)
78+
explaining `as`, `as?`, and `as!`.
79+
80+
### Commits and pull requests
81+
82+
[Slava Pestov](https://twitter.com/slava_pestov) merged [a pull request](https://github.com/apple/swift/pull/32488)
83+
that fixes a bug in generic signature minimization. It [turned out](https://twitter.com/slava_pestov/status/1274914547728515072)
84+
that the fix didn't require a big redesign of the `GenericSignatureBuilder`
85+
after all. It's just a five line addition of a new `'if'` statement.
86+
87+
[Michael Gottesman](https://github.com/gottesmm) merged [a pull request](https://github.com/apple/swift/pull/32627)
88+
that adds an option that causes the generic specializer to validate newly
89+
specialized functions earlier when there is more information that can be put
90+
into a pretty stack trace.
91+
92+
Stephen Celis](https://twitter.com/stephencelis/) merged [a pull request](https://github.com/apple/swift/pull/32451)
93+
that improves performance of `Collection.removeFirst(_:) where Self == SubSequence`.
94+
You can read more about it [here](https://twitter.com/stephencelis/status/1278347623359971328).
95+
96+
[Luciano Almeida](https://github.com/LucianoPAlmeida) merged [a pull request](https://github.com/apple/swift/pull/32376)
97+
that resolves [SR-5688](https://bugs.swift.org/browse/SR-5688): *Unhelpful
98+
diagnostic when missing a ? in a KeyPath expression*.
99+
100+
[Mishal Shah](https://github.com/shahmishal) merged [a pull request](https://github.com/apple/swift/pull/32502) to update master branch for Xcode 12 beta.
101+
102+
### Accepted proposals
103+
104+
[SE-0282](https://forums.swift.org/t/se-0282-review-2-interoperability-with-the-c-atomic-operations-library/37360/12): *Interoperability with the C Atomic Operations Library* was [accepted](https://forums.swift.org/t/accepted-se-0282-interoperability-with-the-c-atomic-operations-library/38050).
105+
106+
> This proposal does not specify whether/how dependency chains arising from the
107+
C/C++ `memory_order_consume` memory ordering work in Swift. The consume ordering
108+
as specified in the C/C++ standards is not implemented in any C/C++ compiler,
109+
and we join the current version of the C++ standard in encouraging Swift
110+
programmers not to use it. We expect to tackle the problem of efficient
111+
traversal of concurrent data structures in future proposals. Meanwhile, Swift
112+
programmers can start building useful concurrency constructs using relaxed,
113+
acquire/release, and sequentially consistent memory orderings imported from C.
114+
115+
### Swift Forums
116+
117+
[Erica Sadun](https://twitter.com/ericasadun) pitched [a proposal](https://forums.swift.org/t/returning-to-an-old-hobbyhorse-migrating-higher-order-function-names-to-comply-with-api-guidelines/37728)
118+
to migrate higher order function names to comply with API guidelines.
119+
120+
> Swift's higher order functions mostly predate the API guidelines and are
121+
based on terms of art. The community debated about this in the past and the
122+
"Term of Art" hammer won at that time. Perhaps we can reconsider now that Swift
123+
is entering its comfortable middle age reflective period as a missed
124+
opportunity.
125+
>
126+
> It would be simple to alias `map`, `filter`, etc with API compliant names
127+
(`apped`, `mapping`, `filtered`, `filtering`), slow-walk-deprecate the former
128+
with the gentlest touch, and move towards a more consistent dev-facing
129+
vocabulary by replacing the terms in the SPL docs and devdoc tutorials (with
130+
footnotes or sidebars) to establish a new standard long before removing the old.
131+
>
132+
> Breaking changes have a high bar so it would take such a slow and cautious
133+
approach to migrate the community towards these changes. Backwards
134+
compatibility would need to be maintained for a longer period of time than
135+
usual. I'm curious as to what people think.
136+
137+
[Erica Sadun](https://twitter.com/ericasadun) pitched [a proposal](https://forums.swift.org/t/extend-swiftpm-packagedescription-to-introduce-metadata/37722)
138+
to extend SwiftPM `PackageDescription` to introduce metadata.
139+
140+
> A Swift Package defines the sources and dependencies for successful
141+
compilation. The [`PackageDescription`](https://docs.swift.org/package-manager/)
142+
specifies items like the supported Swift version, linker settings, and so forth.
143+
>
144+
> What it does not do is offer metadata. You won’t find email for the active
145+
project manager, a list of major authors, descriptive tags, an abstract or
146+
discussion of the package, a link to documentation, deprecation information or
147+
links to superceding packages upon deprecation.
148+
149+
[Doug Gregor](https://twitter.com/dgregor79) starthed [a conversation](https://forums.swift.org/t/revisiting-the-source-compatibility-impact-of-se-0274-concise-magic-file-names/37720)
150+
about revisiting the source compatibility impact of [SE-0274](https://github.com/apple/swift-evolution/blob/master/proposals/0274-magic-file.md):
151+
Concise magic file names.
152+
153+
> In light of the discussion of [principles for (trailing closure) evolution
154+
proposals](https://forums.swift.org/t/principles-for-trailing-closure-evolution-proposals/37265)
155+
and based on feedback we've received from the [Swift 5.3 development snapshots](https://swift.org/download/#snapshots),
156+
I'd like to revisit [SE-0274: Concise magic file names](https://github.com/apple/swift-evolution/blob/master/proposals/0274-magic-file.md).
157+
In particular, I feel like SE-0247 has violated the "Source Compatibility"
158+
principle more than is necessary, and that we should consider revising the
159+
proposal.
160+
>
161+
> SE-0247 includes an additive change (`#filePath` literal to provide the full
162+
path to the file), but then introduces three changes that affect existing
163+
sources:
164+
>
165+
> 1. `#file` literals have a different form that does not include the full path
166+
name. Therefore, the spelling `#file` has changed meaning.
167+
> 2. The compiler provides a warning when a wrapper around a
168+
`#filePath`-defaulting function passes it `#file` instead, or vice versa.
169+
> 3. Standard library functions like `precondition` currently use `#file`, and
170+
therefore have had their behavior changed to no longer produce the full path
171+
name by default.
172+
173+
[Tom Doron](https://forums.swift.org/u/tomerd) shared [meeting notes](https://forums.swift.org/t/june-10th-2020/37863)
174+
for the Swift on the Server Workgroup June 10th, 2020 meeting.
175+
176+
[Frederick Kellison-Linn](https://twitter.com/jumhyn) shared [a proposal](https://forums.swift.org/t/compound-variable-names/37963)
177+
that introduces a syntax for defining function-typed variables which have
178+
compound names.
179+
180+
> This proposal introduces a syntax for defining funciton-typed variables which
181+
have compound names (i.e., names with argument labels). This allows the call
182+
sites of such variables to achieve the same clarity that is achieveable with
183+
`func` declarations.
184+
185+
[Shai Mishali](https://twitter.com/freak4pc) pitched [a proposal](https://forums.swift.org/t/introduce-anonymouskeypath/38080)
186+
to introduce `AnonymousKeyPath`.
187+
188+
> In many challenges of API Designs, you want your consumer to provide a way to
189+
get/set a specific concrete type.
190+
>
191+
> Today, a consumer can express this idea by a Key Path, a wonderful concept in
192+
Swift. My consumer can tell me:
193+
>
194+
> * This is how you can get a String from MyObject (KeyPath)
195+
> * This is how you can mutate a String on MyObject (WritableKeyPath)
196+
>
197+
> Commonly, though, you want to ask a consumer a different set of questions:
198+
>
199+
> * Give me a way to retrieve a String on an arbitrary object
200+
> * Give me a way to mutate a String on an arbitrary object
201+
>
202+
> While not caring what is the Root of that String, as long as you fulfil the
203+
concrete requirement.
204+
>
205+
> Unfortunately, as of today there's no way to express a Key Path which isn't
206+
bound to a specific concrete Root.
207+
208+
[Mattt](https://twitter.com/mattt) gave [an update](https://forums.swift.org/t/swift-package-registry-service-security/38088)
209+
on [a pitch](https://forums.swift.org/t/swift-package-registry-service/37219)
210+
for a Swift package registry service.
211+
212+
> A primary goal of the proposed registry service is to provide strong
213+
guarantees that the package you downloaded is authentic. One approach is built
214+
on trust: If you assume that a registry always sends you exactly what you ask
215+
for, you only need to verify the sender (though it wouldn’t hurt to verify the
216+
contents anyway).
217+
>
218+
> Modern information security relies on [public-key cryptography](https://en.wikipedia.org/wiki/Public-key_cryptography)
219+
to verify claims of identity. Broadly speaking, there are two approaches to
220+
certificate trust:
221+
>
222+
* A centralized, *hierarchical* [public-key infrastructure (PKI)](https://en.wikipedia.org/wiki/Public_key_infrastructure)
223+
scheme, in which [certificate authorities (CAs)](https://en.wikipedia.org/wiki/Certificate_authority)
224+
issue [certificates](https://en.wikipedia.org/wiki/Public_key_certificate)
225+
that prove the ownership of public keys. This is the approach taken by TLS,
226+
which is used by HTTPS.
227+
> * A decentralized, distributed [“web of trust”](https://en.wikipedia.org/wiki/Web_of_trust)
228+
whereby individuals vouch for the identity of one another by signing each
229+
others' keys directly. This is the approach taken by PGP.
230+
>
231+
> The original proposal relies on both TLS and PGP for security; TLS to verify
232+
the identity of the registry’s domain (e.g. github.com) and PGP to verify the
233+
registry as the creator of the package archive. My thinking was that this "belt
234+
and suspenders" approach would offer more security than relying on one alone.
235+
Instead, this turned out to be more of a "weak link in the chain".
236+
237+
### Finally
238+
239+
Finally, we [have](https://twitter.com/Valzevul/status/1275164878056103936)
240+
Nyan Cat in Swift. 🏳️‍🌈
241+
242+
[Acronyms, acronyms everywhere...](https://twitter.com/jckarter/status/1275423569552400384)

0 commit comments

Comments
 (0)