7 ms·
Swift Project in 2023
- virgildotcodes 4y agoDoes this documentation workgroup focus also extend to the documentation of Apple APIs? The pessimist in me thinks no, but I'm hoping to be wrong.
- hazn 4y agoI am fascinated by how the general community perceives swift. The PL theory community seems to appreciate its innovations, while the (online) dev community sees it as Apple's own C#. Ultimately, I think Swift is a hugely underrated language, mainly because of outdated criticism.
- pjmlp 4y agoWell, the fact is that it is as open source as Objective-C, and that it has hardly helped the latter without the frameworks that really matter. There is no issue in being Apple's C#, this is the only way for bringing safety computing forward, having the platform owner making it happen no matter what.
- johnthuss 4y agoI don't think this is true. Apple provides a fairly substantial standard library along with the open source version of Swift, which they never did for Objective-C.
- pjmlp 4y agoWe have very different point of views what fairly substantial means, specially in absence of any Apple ecosystem key framework and XCode tooling.
- ofrzeta 4y agoOpen Source Swift will never become a language for graphical applications. Same problem as with Objective-C as you said. There's GNUstep but look how far they have come in decades. On the other hand a bunch of useful libs (based on said standard lib) for server-side Swift is realistic.
- pjmlp 4y agoServer side Swift lags behind the competition and only makes sense for Apple shops to write their apps backends.
- bsaul 4y agoEven for apple shops, it doesn’t really makes sense. It is a myth to think that you can share anything of value between client and servers, except dumb data types that you’ll probably want to define in protobuf anyway for various reasons. As for knowing the language, you’d gain the two weeks it takes to learn go, but you’ll loose all the ecosystem of quality libraries.
- pjmlp 4y agoApparently a myth made reality on the Apple shops I know. It is no different from the Android shops using Java and Kotlin for the backend, the only difference being the plethora of options on the JVM ecosystem that they can reach out outside Android.
- d3nj4l 4y ago> The PL theory community seems to appreciate its innovations I'm curious as to what these innovations are. I've not looked too deeply into Swift - I've played around with SwiftUI a bit and nothing else - but from what I saw I didn't see any fundamentally novel ways to do things. People talk about protocols/actors etc, but I've seen other languages that do those and (IMO) better. If anything, I thought the emphasis on creating new forms of syntax for things that should've been built as more fundamental, orthogonal concepts (eg. `guard let` etc.) would've made it more distasteful to the PL theory crowd, who love orthogonality IME. (I'm sorry if I'm coming off as sarcastic/combative, I'm genuinely curious about this!)
- favorited 4y agoThe Swift story around ABI stability and library evolution is pretty unique. Relatedly, its approach to generics doesn't fall into either of the 2 traditional paths (either box everything like Java and C#, or template instantiation like C++ or Rust). https://faultlore.com/blah/swift-abi/ https://faultlore.com/blah/swift-abi/ https://www.youtube.com/watch?v=ctS8FzqcRug https://www.youtube.com/watch?v=ctS8FzqcRug
- cwzwarich 4y agoThe closest thing to Swift’s approach to polymorphism in the academic world is intensional polymorphism: https://www.cs.cmu.edu/~rwh/papers/intensional/popl95.pdf https://www.cs.cmu.edu/~rwh/papers/intensional/popl95.pdf
- hazn 4y agoHow Swift Achieved Dynamic Linking Where Rust Couldn't: https://faultlore.com/blah/swift-abi/ https://faultlore.com/blah/swift-abi/ Many programming languages list Swift as inspiration: https://www.val-lang.dev/ https://www.val-lang.dev/ Rust's optional bindings are inspired by swift: https://doc.rust-lang.org/reference/influences.html https://doc.rust-lang.org/reference/influences.html (Many people who worked on Rust also worked on Swift, like the creator of rust) The SwiftUI framework you mentioned uses inspiring syntax, which has been tried do be emulated (Jetpack Compose, Druid). However, nobody got it as magical as Swift did. The way SwiftUI Syntax combines pl theory and developer usability is amazing.
- deleted 4y ago[deleted]
- kaba0 4y ago> The PL theory community seems to appreciate its innovations Is that the case? The language started out interesting, but it took a turn for the worse and has become a kitchen-sink with every single feature from any language being found in it, but their interactions are simply not designed well. But what innovation did it have? I can’t think of any one feature that would be novel, as in no other mainstream language would have experimented with it. That said, I think it really was a great language, and there is a sane subset that is still great, don’t want to start a flame war :D
- halfmatthalfcat 4y agoI've very anxiously awaiting Swift on Server's development/maturity. My love for Scala/Akka (especially with the latest licensing changes) could potentially be replaced if they nail Distributed Actors.
- mk89 4y ago> My love for Scala/Akka (especially with the latest licensing changes) could potentially be replaced if they nail Distributed Actors. Considering they hired one of the major akka core developers[0] to work exactly on the Actor model for Swift, I would say they have all the knowledge to nail it. [0]: https://github.com/ktoso https://github.com/ktoso
- mk89 4y agoJust stumbled upon this: https://developer.apple.com/documentation/distributed https://developer.apple.com/documentation/distributed is this not good enough?
- ofrzeta 4y agoDid you take a look at Dotnet Orleans?
- Kukumber 4y agoApple has its own better Rust now Swift: - Servers - OS - Apps with a wonderful SwiftUI framework - C++ Interop - Ownership model - Crossplatform
- johnthuss 4y agoSince it is open source and supports Linux and Windows too we all have it, not just Apple.
- Daedren 4y agoSwiftUI is not open source and doesn't support other platforms.
- Arcanum-XIII 4y agoWell, every time I heard about the SwiftUI it’s to complain about the hidden complexity and difficulty to debug it. Not so sure it’s a true plus! And it’s only valid on Mac/iOS
- jakey_bakey 4y agoSwiftUI was historically pretty dire to debug, but in the 3 years since release it's come on in leaps and bounds - Apple, for once, released something before it was production-ready and actually listened to feedback
- msie 4y agoAny website to follow who's doing extensive Linux programming with Swift and writing about it?
- runjake 4y agoI'm not sure if any exist, but this link[1] pulls up this link[2]. 1. https://pinboard.in/t:swift/t:linux/ https://pinboard.in/t:swift/t:linux/ 2. https://www.kodeco.com/8325890-a-complete-guide-to-swift-development-on-linux https://www.kodeco.com/8325890-a-complete-guide-to-swift-dev... (formerly raywenderlich.com)
- bradhilton 4y agoGlad to see they are still working on differentiable Swift.
- zapnuk 4y agoBetter AWS Lambda support would be nice. There is a runtime by the server workgroup but afaik it requires docker as an intermediate for compilation. If would be awesome if the cross compilation support is as good as it is in Go such that you could build your lambda executable with `GOOS=linux GOARCH=amd64 go build -o main main.go`.
- danielscrubs 4y agoI really hope they make some changes to the Swift language to make it quicker to compile. I never again want to see: “Expression was too complex to be solved in reasonable time; consider breaking up the expression into distinct sub-expressions.” https://stackoverflow.com/questions/33794574/swift-expression-was-too-complex-to-be-solved-in-reasonable-time?rq=1 https://stackoverflow.com/questions/33794574/swift-expressio... For a dumb example see: https://forums.swift.org/t/why-is-swift-so-slow-timeout-in-compiling-this-code/61382 https://forums.swift.org/t/why-is-swift-so-slow-timeout-in-c... That said I do enjoy the language.
- PoignardAzur 4y agoOh man, variadic generics. I hope the hope they do on that feature inspires Rust to follow suit. This is a game-changer in terms of expressiveness.
- bsaul 4y agoDo you have any example of the kind of things that it would enable ? I must say i've never had the need for this feature, but maybe it's just because i've never used a language that had it..
- PoignardAzur 4y agoIt would allow you to write type constructors over lists of types. For instance, if you're writing an ECS manager, you could write something like: struct SystemManager<...Systems: System> { ... } // in user code let my_system: SystemManager<Collisions, 3dModels, PlayerInput, Networking, EnemyAi> = ... Also, it would make it a lot easier to write some macros; with variadic generics, derive macros could just generate a call to a variadic implementation (thus producing fewer tokens, thus better compile times), and have that implementation handle the bulk of the logic. Unlike a macro body, this macro would be type-checked at the writing site, leading to fewer post-monomorphization errors.