Swiftweekly.github.io: [126] Issue #126 - January 24, 2019

Created on 10 Jan 2019  路  18Comments  路  Source: SwiftWeekly/swiftweekly.github.io

To contribute to this issue, simply leave a comment here. Please also review our contributing guidelines.

The current draft for this issue in _drafts/. If you want to contribute directly, feel free to open a pull request.

full issue notes

Most helpful comment

https://twitter.com/cocoawithlove/status/1086581405625180161

I played around with Swift master's new stack allocated closure contexts today. My "capturing closure" mutex test case from this article:

http://www.cocoawithlove.com/blog/2016/06/02/threads-and-mutexes.html

improved 10x from 2.051 seconds to 0.212 seconds. Putting it within 20% of the inlined version.

All 18 comments

I've finished up an interesting research project, trying to answer the question: is Swift a good language for high performance numeric programming in Mac and Linux? And the answer: yes it is!

I think this has the potential to be great for data science.

https://www.fast.ai/2019/01/10/swift-numerics/ https://twitter.com/jeremyphoward/status/1083440518527217664/photo/1

https://github.com/apple/swift-evolution/pull/974

Introduces a folding operator that seeds itself from the elements passed to reduce, removing the need for an explicit value seed.

This proposal adds a "simple, useful (if fairly low-priority) addition" to the standard library.

Sent with GitHawk

239 accepted

Swift scripts without any dependencies https://github.com/mxcl/swift-sh

Sent with GitHawk

Deep dive into subtleties of protocol extensions

https://swiftindepth.com/2019-01-13/the-subtleties-of-protocol-extensions

Initiative by @loiclec adding support for fuzz testers in Swift packages

https://forums.swift.org/t/support-for-fuzz-testers-in-swift-packages/19494

https://twitter.com/dgregor79/status/1085057290468614145

SwiftLang SE-0240 :Ordered Collection Diffing" is in review until January 22nd, 2019: https://forums.swift.org/t/se-0240-ordered-collection-diffing/19514

Trailing commas in all expression lists

https://github.com/apple/swift-evolution/pull/976

Sent with GitHawk

https://twitter.com/slava_pestov/status/1085691914328920066

Short history of non-escaping functions:

  • Swift 4.1 and earlier: type checker enforcement; same ABI as escaping
  • Swift 4.2: new ABI - the context is a trivial pointer and not ref-counted like with escaping
  • now: non-escaping contexts allocated on stack https://github.com/apple/swift/pull/21933

https://twitter.com/slava_pestov/status/1085692131623256066

Best kind of bug fix - combine two code paths, fixing edge case neither one could handle: https://github.com/apple/swift/pull/21932

https://twitter.com/jckarter/status/1085965768527773696

If you want to try out opaque result types in Swift, I now have a prototype implementation: https://forums.swift.org/t/opaque-result-types/15645/250

https://twitter.com/cocoawithlove/status/1086581405625180161

I played around with Swift master's new stack allocated closure contexts today. My "capturing closure" mutex test case from this article:

http://www.cocoawithlove.com/blog/2016/06/02/threads-and-mutexes.html

improved 10x from 2.051 seconds to 0.212 seconds. Putting it within 20% of the inlined version.

Published 馃帀, thanks a lot for helping out again, @fassko!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

BasThomas picture BasThomas  路  4Comments

jessesquires picture jessesquires  路  6Comments

jessesquires picture jessesquires  路  9Comments

jessesquires picture jessesquires  路  5Comments

jessesquires picture jessesquires  路  10Comments