TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

What's new in Swift 4.1

84 点作者 OberstKrueger超过 7 年前

6 条评论

PopsiclePete超过 7 年前
Is this used outside the Apple eco-system much? I admit I haven&#x27;t looked at Swift in 2 years or more.<p>I find the omission of features like namespaces really strange. I realize that namespaces don&#x27;t jive with how Obj-C and Obj-C frameworks see the world and that Swift and Obj-C need to play together, but dealing with global namespace pollution and collisions in 2018 just seems...sad? They&#x27;re hobbling the language in various ways due to NS*&#x2F;Cocoa framework stuff.<p>Another weird omission is lack of any kind of concurrency story. Right now, this just seems like Apple&#x27;s &quot;me-too&quot; version of Java&#x2F;C#, but what does it actually bring to the table that would make it a worth-while investment if I&#x27;m not an iOS developer?
评论 #16227331 未加载
评论 #16227789 未加载
评论 #16227333 未加载
评论 #16227975 未加载
评论 #16227602 未加载
评论 #16227740 未加载
beefsack超过 7 年前
This is great news for developers who use Apple products.<p>I&#x27;m happy they&#x27;re trying to improve the cross-platform story but I&#x27;m not sure I could ever completely trust the ecosystem when it&#x27;s so tightly bound to MacOS&#x2F;iOS (standard library still not complete, 3rd party libraries may only work or be well tested on Apple platforms, new features may take time to land on other platforms.)
评论 #16227471 未加载
评论 #16228342 未加载
adamnemecek超过 7 年前
conditional conformance is a game changer.
评论 #16229701 未加载
评论 #16227505 未加载
dennisvennink超过 7 年前
Implementing conditional conformances alone removed a lot of duplicate code from the standard library. I always like to think that the amount of gyb[^1] files in the source code is a good indicator of how far Swift is in its development.<p>[1]: gyb, a template processor, is a workaround for features that the standard library needs, but that are not (completely) implemented yet.
tabs_masterrace超过 7 年前
Can anyone explain whats the reasoning behind renaming flatMap?
评论 #16229911 未加载
hacker_9超过 7 年前
<i>&quot;things that didn&#x27;t work before will now&quot;</i><p>Just the words I want to hear when I upgrade my programming language by one minor version.
评论 #16227624 未加载
评论 #16227619 未加载
评论 #16227732 未加载
评论 #16228426 未加载