Swift 5.9 Released | Prime Reacts

  Переглядів 58,760

ThePrimeTime

ThePrimeTime

7 місяців тому

Recorded live on twitch, GET IN
/ theprimeagen
Reviewed article: www.swift.org/blog/swift-5.9-...
Authors: Alexander Sandberg - x.com/alexandberg?s=20 |
Holly Borla - x.com/hollyborla?s=20
MY MAIN YT CHANNEL: Has well edited engineering videos
/ theprimeagen
Discord
/ discord
Have something for me to read or react to?: / theprimeagenreact
Hey I am sponsored by Turso, an edge database. I think they are pretty neet. Give them a try for free and if you want you can get a decent amount off (the free tier is the best (better than planetscale or any other))
turso.tech/deeznuts

КОМЕНТАРІ: 332
@ConernicusRex
@ConernicusRex 6 місяців тому
Favorite language hands down. It’s absolutely amazing. Perfect syntax, tiny footprint, bare metal programming, best type system, and seamless multi threading and concurrency. “Better Rust,” is a very good way to put it.
@georgeelsham
@georgeelsham 6 місяців тому
My favourite language too, and very much agree on the type system. I’ve had a list of things Rust does worse than Swift, especially with the type system, but I’m glad to see Rust start to tick a few of those off my list. The two languages really are competing but also working together which is great.
@isodoubIet
@isodoubIet 6 місяців тому
Lost all interest in swift when I learned about the absurd callback syntax.
@Xaxxus
@Xaxxus 6 місяців тому
@@isodoubIet swift has concurrency now. One of the best concurrency systems of any language. You can now use standard async await for async functions instead of having to deal with callbacks.
@zollerboy1429
@zollerboy1429 6 місяців тому
@@isodoubIetwhich callback syntax?
@isodoubIet
@isodoubIet 6 місяців тому
@@zollerboy1429 When you call a function that takes a callback as the last argument, the body of the callback goes outside the function call. Like if you were to pass a lambda to a function in C++ it would be as if you did it like this: std::ranges::sort(v, {}, [](std::string s)) { return s.size(); // sort according to length } Just all around baffling. Swift is a weird language like that. You see the list of features, nod along like "yes, yes, that is a good idea, yes, it seems nice"... and then you spot the exact moment where the designers popped an aneurysm.
@kenneth_romero
@kenneth_romero 6 місяців тому
gotta remember chris latner was a lead designer for swift. dude really is a genius.
@aalecaar
@aalecaar 6 місяців тому
Many Swift features were heavily inspired by Rust. Even Graydon Hoare, the creator of Rust himself, joined the Swift team and contributed to it short after the language was launched. I think that's an interesting fact to be aware of too
@atkascha
@atkascha 6 місяців тому
I think... you may have your sentence backwards, or do you mean 5.x? Swift came out in 2014. Rust came out in 2015. Hard to be _inspired by_ something when you release before.
@villuna_
@villuna_ 6 місяців тому
the first *stable* release of rust came out in 2015. also languages are constantly being developed so they probably inspired each other, regardless of who technically came out "first".
@ConernicusRex
@ConernicusRex 6 місяців тому
Swift came first, my man.
@RX793
@RX793 6 місяців тому
Not true
@NamanGoel34
@NamanGoel34 5 місяців тому
Both languages inspired each other. And both stole liberally from existing FP languages.
@SXsoft99
@SXsoft99 6 місяців тому
I looked at Swift a few years back when i worked with a ios developer and was kinda blown away how good the code base was you can shit on apple on a lot of points but not the language
@corpseopera
@corpseopera 6 місяців тому
it was made by the god himself Chris Lattner
@mattymerr701
@mattymerr701 6 місяців тому
Can you shit on them for Objective C at least?
@pwinowski
@pwinowski 6 місяців тому
My point exactly (well maybe let's not get carried away with the 'god' tag). But man, isn't that man a genius?!@@corpseopera
@corpseopera
@corpseopera 6 місяців тому
@@pwinowski then legend?
@ConernicusRex
@ConernicusRex 6 місяців тому
The man’s reputation can float on the LLVM alone for the next 25 years but he keeps coming up with new great ideas. Pretty incredible mind.
@calinnilie
@calinnilie 6 місяців тому
Swift seems really cool, too bad it's not been adopted almost anywhere except the Apple ecosystem.
@GOTHICforLIFE1
@GOTHICforLIFE1 6 місяців тому
That can change though if the popularity increases, and they manage to disassociate Swift from Apple. Much like C# isn't only for Windows specific operations, even though it's certainly the best option for Windows development
@calinnilie
@calinnilie 6 місяців тому
Apple made the right move here by open sourcing it, and it is indeed on us to adopt it I guess@@GOTHICforLIFE1
@oserodal2702
@oserodal2702 6 місяців тому
I think its cause it's a pain in the ass to use on Windows. I've watched a couple of times from Fireship where he says that he switches to a Mac machine when using Swift, whereas in other languages, he is mostly Windows to record.
@bdkamil95
@bdkamil95 6 місяців тому
@@oserodal2702 windows sucks for development anyway (except when you develop for windows)
@Stabby666
@Stabby666 6 місяців тому
@@GOTHICforLIFE1well it’s not the best option for windows development if you’re already a C++ dev. I can write both but always use C++ for new projects.
@bgill7475
@bgill7475 6 місяців тому
I like that he's willing to learn and try it out. I really like Swift, his use case seems much different to what I use it for but hopefully he finds it interesting when he tries it out.
@coke2679
@coke2679 6 місяців тому
I'm a big swifty. Hate xcode, love swift. Apple managed to create the worst IDE and the best language.
@Shivam-to8wc
@Shivam-to8wc 6 місяців тому
True 😂
@BigfootPrinting
@BigfootPrinting 6 місяців тому
How’s the swift LSP experience these days?
@FrankJonen
@FrankJonen 6 місяців тому
I don’t think there are people who actually like Xcode outside of the official testimonials. It’s so slow and takes forever to launch.
@JonnoTheBonno
@JonnoTheBonno 6 місяців тому
Could not agree more. Love swift. Xcode literally ruins my life
@NamanGoel34
@NamanGoel34 6 місяців тому
@@BigfootPrintingI’ve used the LSP in VSCode and it’s OK.
@MessioticRambles
@MessioticRambles 6 місяців тому
Swift's a lot like Rust in a tonne of ways, except the coolest thing that I don't think most people know about is how they do generics right. Swift doesn't monomorphise its generics into specific implementations in library code, so it doesn't take a MyType and turn it into a MyTypeInt and MyTypeString and a new type for every possible use case known at compile time. Which is what Rust and Go and such will do. Nor does it just type erase everything so that MyType is just MyType under the hood. Akin to Java. A MyType stays as a MyType, in the compiled code, so you can just have the lib headers (no source) and you'll be able to link against a library that uses generic types and it'll work.
@Alex-kb2ws
@Alex-kb2ws 6 місяців тому
The C# effect
@ConernicusRex
@ConernicusRex 6 місяців тому
The generic system is the best I’ve ever seen and it isn’t even close. I’m consistently surprised at how seamlessly it works.
@kira.herself
@kira.herself 6 місяців тому
how does this work it sounds very interestingyou got any articles on that on how that works deep down?
@testtest-qm7cj
@testtest-qm7cj 6 місяців тому
@@kira.herself There is a UKposts video named "Implementing Swift Generics, " from an LLVM meeting.
@isodoubIet
@isodoubIet 6 місяців тому
There's a reason why types are monomorphized at compile time. It means you can get generics without paying the cost of virtual functions. This is a different tradeoff (usability for new types at the expense of performance), not "doing generics right".
@vladislavkovechenkov8473
@vladislavkovechenkov8473 6 місяців тому
It‘s amazing how one can radiate excitement about tech! Thanks for the video. I was playing around with Swift at some point and was greatly surprised how „ergonomic“ (for a lack of a better word) it feels. I didn’t have much experience with programming back then, but learning Swift after JavaScript was quite fun. Didn’t stick to it as lots of products back then were still in Obj-C, supporting clients on older iOS versions etc. But watching this video got me thinking to go and look into Metal and continue to learn. Thanks!
@igorordecha
@igorordecha 6 місяців тому
i honestly don't understand why they care so much about supporting this niche operating system *specifically* designed for gaming.
@robonator2945
@robonator2945 6 місяців тому
especially since it's been deprecated since July 2021. I mean there are a few incompatibilities with the newer standard sure but at the end of the day not sure why you'd bother keeping an entire system around just because a few developers like to go out of their way to screw you over, seems weird IMO.
@mcritz46vl
@mcritz46vl 6 місяців тому
I love Swift. It’s come a long way of being more of a general purpose language. Language server works well. There’s packages for cross platform GUIs. Vapor, Hummingbird, Smoke, and the Swift runtime for AWS Lambda have made Swift development for servers very interesting.
@ConernicusRex
@ConernicusRex 6 місяців тому
Vapor is competing with Go to be my favorite thing for the backend.
@victorpinasarnault9135
@victorpinasarnault9135 6 місяців тому
What about PHP?
@evergreen-
@evergreen- 6 місяців тому
Swift mentioned, LET’S GO
@pouris
@pouris 6 місяців тому
If bidirectional interoperability really works with C++ without the need for a use of a manual bindgen, kinda like zig's cImport then it's freaking awesome
@ruanpingshan
@ruanpingshan 6 місяців тому
I used to use Swift in my previous job. It's living proof that a great language is nothing without the right ecosystem. I ended up having to use Objective C++ for some tasks because there were no good Swift libraries for linear algebra like Eigen in C++.
@JamesPower
@JamesPower 3 місяці тому
And now you can just import the C++ library you want!
@simonlundberg8194
@simonlundberg8194 6 місяців тому
Swift is really nice, but I just use it to write CLI tools for my general workflow stuff. It's a very nice language. If adoption picks up and the eco system grows, it seems like it'd be a great choice for many situations. Out of all language I've used, I think Swift has the nicest approach to memory. You can be lazy and just let the ARC deal with almost everything and selectively optimise some parts with more explicitly managed memory. It's a great approach.
@AK-vx4dy
@AK-vx4dy 6 місяців тому
Comptime and macros are for different pruproses. Macros are for easy use of new features or mundane parts. Comptime is for calculating what is possible AOT or code generation but in more modular way
@andnekon
@andnekon 6 місяців тому
cumtime
@sacredgeometry
@sacredgeometry 6 місяців тому
Swift is way better than rust and even it still feels very new. 0:35 FINALLY! I have been waiting for C++ integration since release. I guess I need to get back to work on my DAW.
@im-essi
@im-essi 6 місяців тому
I've written a bit of swift, it's pretty nice. Looking at picking up zig atm, but otherwise swift mightve been it. Worth checking out imo
@andrewdunbar828
@andrewdunbar828 6 місяців тому
If you like one you ought to like the other. Both communities are pretty friendly and helpful too but it can be harder to find Swift people when you need help with a problem.
@im-essi
@im-essi 6 місяців тому
@@andrewdunbar828 Yeah, I'm getting similar nice vibes from both :) I think I'm covered on the swift front luckily as the entire iOS team at work writes it, and they're all a friendly bunch
@hrmny_
@hrmny_ 6 місяців тому
cargo expand is built into the ra vscode extension and rustrover (and it's very granular per macro call)
@conradtaylor29
@conradtaylor29 6 місяців тому
@ThePrimeTime If you're using Swift Macros, one can easily expand macros to see its generated Swift code within Xcode.
@rogersmith258
@rogersmith258 6 місяців тому
I installed V, it was fun from what little of it I got to use. Maybe I'll give Swift a shot.
@elsolem
@elsolem 6 місяців тому
Part of the reason I use Odin is cause once you leave iOS you are on your own, but I still keep up with it cause its a dope lang
@chromerims
@chromerims 6 місяців тому
This channel's coeff of entertaining is real.
@MarkJaquith
@MarkJaquith 6 місяців тому
It's as good as it looks. Hands down my favorite language of all time. Just a delight.
@eugeniomachado3394
@eugeniomachado3394 6 місяців тому
good to hear you talking about some taylor swift, been programming in that for the last 8 months, and I'm having a blast after so many years dealing with Java/JS shait
@andrej2321
@andrej2321 6 місяців тому
Oh no. What a discovery. You must think ahTML is a language. Fing batch or Basic is better language than JS or Java. Why the slash. As if the two were related 😂
@eugeniomachado3394
@eugeniomachado3394 6 місяців тому
Andrej is a genius.
@ConernicusRex
@ConernicusRex 6 місяців тому
Do you… think Java and JavaScript are somehow related or interchangeable?
@andrewdunbar828
@andrewdunbar828 6 місяців тому
Swift is pretty nice and you should look at it. It's easier than Rust because it doesn't try to do the hard stuff Rust tries. It's a bit more comparable to Zig. I like all three.
@gombike95
@gombike95 6 місяців тому
Talking about Ocaml and html templating.. have you seen TyXML with Reacon's JSX like syntax?
@shreyanshmishra6613
@shreyanshmishra6613 6 місяців тому
Arc browser is using it on windows. Its a great start.
@kosnowman
@kosnowman 6 місяців тому
Go Swift!!!!!
@mintx1720
@mintx1720 6 місяців тому
It would be funny if swift 25.0 become twice as good as rust and still nobody notices.
@Devenias
@Devenias 6 місяців тому
Can you do a video or live stream where you show how you learn a new language? So what is your approach, and what steps do you follow? Would be nice to see how other engineers get into a new language. Something like 0 to hero in Swift...
@Art-is-craft
@Art-is-craft 4 місяці тому
You learn from your own base techniques.
@Devenias
@Devenias 4 місяці тому
@@Art-is-craft sure I do, but I want to know how other people do it to improve my way of learning by picking some methods that fit my current style.
@Art-is-craft
@Art-is-craft 4 місяці тому
@@Devenias There is SICP and HTDP that can provide base techniques that can be transferred to various languages. MIT course in Python also tries to do the same. My basis is the SICP approach to programming that I have transferred to various languages.
@krumbergify
@krumbergify 6 місяців тому
The term parameter pack comes from modern C++, but in C++ they are almost like a language within a language. You can do ”for each” on a pack, but the syntax is weird.
@mcritz46vl
@mcritz46vl 6 місяців тому
I love using Plot as an HTML “DSL” (domain specific language). You can write type-safe HTML. I am just now binding HTMX directives into Plot.
@JamesPower
@JamesPower 3 місяці тому
I’m doing the same thing with swift-html!
@jcfawerd
@jcfawerd 6 місяців тому
BTW, if-let is a syntax started by Swift, and then copied by Rust
@MessioticRambles
@MessioticRambles 6 місяців тому
There's a lot of borrowing between the two. I find it funny that surface level, Swift syntax looks closest to something like Kotlin. But in terms of actual concepts and features, Swift and Rust are basically twins.
@andrewdunbar828
@andrewdunbar828 6 місяців тому
Some key people have worked on both.
@aalecaar
@aalecaar 6 місяців тому
@@andrewdunbar828Yep, as I said before in a comment, the creator of Rust, Graydon Hoare, joined the Swift team and contributed to the language short after it was launched
@ConernicusRex
@ConernicusRex 6 місяців тому
Conditional unwrapping is 🔥
@ceopaludetto
@ceopaludetto 6 місяців тому
I really like Swift, sourcekit lsp is evolving as well
@Compscinshit
@Compscinshit 24 дні тому
Less debug. I forgot the term but from my understanding.. it’s way easier to find bugs. Everything is like connected or able to be linked.. which basically means it’s all linked.
@yaksher
@yaksher 6 місяців тому
"OCaml has an amazing standard" OCaml doesn't even have strstr in its standard library.
@SergKoshelev
@SergKoshelev 6 місяців тому
Swift has Vapor framework, it's fast and easy to use
@victorpinasarnault9135
@victorpinasarnault9135 6 місяців тому
Swift can be written in Linux, I Love that.
@parsanasirimehr7267
@parsanasirimehr7267 6 місяців тому
XCode let's you expand the macro directly in the code.
@praus
@praus 6 місяців тому
Swift has been really fun to learn and use. It does feel a lot like Rust in some ways. It’s also pretty fast. There’s a reason Apple uses it to write everything from Mac OS to all of its apps. It delivers some great performance and safety.
@thedeemon
@thedeemon 6 місяців тому
Apple doesn't really use it that much in its own products.
@Art-is-craft
@Art-is-craft 4 місяці тому
@@thedeemon You mean they use C and C++ to get to the heart of the machine. Nothing wrong with that and Swift allows that integration as it was built on top of C.
@melodyogonna
@melodyogonna 2 місяці тому
@@thedeemon Are they picking C/C++/Objective-C for new projects? Can't expect them to rewrite existing software in Swift.
@flurium
@flurium 6 місяців тому
Waiting jsx in swift and htmx stuff
@JamesPower
@JamesPower 6 місяців тому
It's really nice
@vncntjms
@vncntjms 6 місяців тому
Okay I've got more reasons to learn Swift now aside from having the same name as Taylor.
@danvilela
@danvilela 6 місяців тому
My new stack: swift and elixir 😊
@JorgetePanete
@JorgetePanete 6 місяців тому
Objective-Rust#
@Amzdgg
@Amzdgg 2 місяці тому
The LSP is not in mason because it is bundled with swift, so it will always have the same version as the swift version you are using
@Mempler
@Mempler 6 місяців тому
I recently got a mac mini, just for learning dev in their ecosystem since i learned win32 and linux+gtk+qt already. Now i'm about to learn swift, feels weird rn. Especially since i'm not used to Xcode and especially macs keyboard bindings
@perc-ai
@perc-ai 6 місяців тому
that sounds fun
@Mempler
@Mempler 6 місяців тому
gotta say, xcode's builtin documentation tool is insane. Similar to man pages but much more complex and powerful. even more powerful than markdown pages
@RodyDavis
@RodyDavis 6 місяців тому
Swift was my first programming language! Swift 1.0
@rokker333
@rokker333 2 місяці тому
I am 52 years old. I started with Assembly and C. Did C++ for the most of my time. I did a little bit of Java, when I had to but tried to avoid it. I did JS when I was physically forced to do FE. And a bit of scripting (Python, Perl) and ABAP stuff on SAP. I tried to avoid C# and hated Objective C from the bottom of my heart. That said, Swift is the most exciting stuff in Software Development for a long long time. Only thing is that for my taste it is a litte bit too ambigious. But all in all well crafted and exciting technology.
@dewigesrek5651
@dewigesrek5651 6 місяців тому
swift is a great language tbh
@anshulsanghi8161
@anshulsanghi8161 6 місяців тому
I believe you can even put debug breakpoints inside swift macros.
@ArtemShoobovych
@ArtemShoobovych 6 місяців тому
Zig claims to have macros as sane as possible. Did not try them yet tho
@HelloWorld-hf7zv
@HelloWorld-hf7zv 6 місяців тому
so happy to be in my last months of software development career...no more f**** to give about what's new
@fishsayhelo9872
@fishsayhelo9872 6 місяців тому
based comment
@VivekYadav-ds8oz
@VivekYadav-ds8oz 6 місяців тому
Damn ... any advice to give to us younglings? And congrats on the retirement! (hope it's retirement and not the other possibility 💀)
@ConernicusRex
@ConernicusRex 6 місяців тому
Man. Another gets PIP’d. You hate to see it.
@platin2148
@platin2148 5 днів тому
Swift Feels like C++ in the aspects of stuff that it adds..
@lcarsos
@lcarsos 6 місяців тому
D had macros that work like Zig's comptime. But nobody ended up using D. :(
@RickyGarcia_Learning
@RickyGarcia_Learning 4 місяці тому
swift is awesome
@suirad4life
@suirad4life 6 місяців тому
Pony lang has gc and borrow checking and ownership
@edborowski5950
@edborowski5950 6 місяців тому
If you were here we'd laugh about their vacant stares.. but right now.. my time is theirs.
@oefzdegoeggl
@oefzdegoeggl 6 місяців тому
yeah swift is nice, though i use it only on iOS. i see it pretty equal from the learning curve to kotlin and dart, i use all of them and can quickly switch. actually i did the android version of some app by literally copy+paste the swift code into android studio and manually fixing the obvious syntax errors and manually fixing non-portable constructs like task/coroutine handling. that went pretty quick - on a port from/to rust, i'd not even try this but rewrite from scatch. (for backend stuff, i still prefer rust).
@joranmulderij
@joranmulderij 6 місяців тому
I’ve done this from js to dart and that also kinda works
@Art-is-craft
@Art-is-craft 4 місяці тому
kotlin is not that much outside of Android. Same for C# and Microsoft.
@KevinLoustau
@KevinLoustau 5 місяців тому
waiting for your video on swift.......
@karmatraining
@karmatraining 6 місяців тому
Swift on Windows? Mind blown!
@apollolux
@apollolux 6 місяців тому
When Swift was first released, I was surprised at how similar it originally looked to JavaScript back then. Unfortunately, due to many factors I didn't keep up with it and if I saw it now I wouldn't even recognize it. If I want to make iOS apps now like I wanted to in the past (my whole reason for getting a MacBook Air in the first place) I'd have to learn Swift from zero again.
@binitrupakheti4246
@binitrupakheti4246 6 місяців тому
I didn't even know swift was cross platform.
@Shivam-to8wc
@Shivam-to8wc 6 місяців тому
It's very hard to use Swift on windows
@danvilela
@danvilela 6 місяців тому
“Crossplatform” === ios, ipados, macos, watchos, tvos……
@ConernicusRex
@ConernicusRex 6 місяців тому
Yep. Windows and Linux have been supported since 2020.
@NamanGoel34
@NamanGoel34 6 місяців тому
Swift has had Linux Support for almost a decade. Windows support has always been an afterthought.
@SilisAlin
@SilisAlin 6 місяців тому
@@NamanGoel34bro Swift itself is not even a decade old lmao
@pif5023
@pif5023 6 місяців тому
Prime buying the Taylor versions of the albums
@unlisto
@unlisto 6 місяців тому
I know people will say a lot if I say I use swift for my Quant engine...
@eternaljunior
@eternaljunior 6 місяців тому
If you could do Swift outside of xcode without problems it would be one of the best languages imho
@NamanGoel34
@NamanGoel34 6 місяців тому
Swift ships with an LSP. I’ve tried in VS Code and it works OK.
@Melgaer
@Melgaer 6 місяців тому
I was hoping that that is true, but after doing some more serious work - vim with sourcekit lsp is an inferior experience to xcode, regarding how language features work. That makes me really sad as nvim user that has to write few thousands line of code in Swift in next months.
@webdavis
@webdavis 2 місяці тому
I love Swift. It really is a beautiful language. That being said, the biggest problem with Swift is the iOS community. It just seems like the community is really far behind a lot of other coding communities in terms of best practices. I can't tell you the amount of folks I have met that don't understand that MVC is a UI Layer pattern or that MVVM is a presentation layer patter. They think they should use them for the whole onion and it leads to a lot of spaghetti code. I don't know, there's just a lot of pattern chasing in the iOS community in general. Whatever the newest one is then that's the one that will magically fix your codebase: kinda like JavaScript and frameworks.
@uuu12343
@uuu12343 6 місяців тому
Taylor swift is so talented Singer, cybersecurity specialist and now, super powerful programming tool??
@griffinbaker860
@griffinbaker860 6 місяців тому
Fell in love w Swift after 2 days of using it
@andrej2321
@andrej2321 6 місяців тому
Swift is in the same category of Apple fails as MobileMe
@stanrock8015
@stanrock8015 6 місяців тому
I also do not know Swift. Reading it does support inheritance and composition which is weird. How does that work out in the long run?
@amomchilov
@amomchilov 6 місяців тому
There’s classes and class-based OOP, mainly for Objective C interop (e.g. so you can use existing libraries, without needing to rewrite the world like Go). But most idiomatic Swift uses protocols and structs, in a more Rust-like style
@ConernicusRex
@ConernicusRex 6 місяців тому
My brother in Christ have you never used a multi paradigm language like Rust, Kotlin, or Go? Same shit.
@perc-ai
@perc-ai 6 місяців тому
its a revolutionary language you should give a try
@SilisAlin
@SilisAlin 6 місяців тому
I’m genuinely curious to know what language you use that doesn’t support both?
@aus10d
@aus10d 6 місяців тому
13:33 I also would love an easy-syntax language like Go with Rust's type system. That sounds amazing. Prime, let us know if you find it!
@NamanGoel34
@NamanGoel34 6 місяців тому
It’s called Swift.😂
@georgeelsham
@georgeelsham 6 місяців тому
Yea I think Swift’s type system is much better than Rust’s - I found quite a few things missing in Rust, but Rust is catching up a bit which is nice to see.
@aus10d
@aus10d 6 місяців тому
Thanks, guys. I read some on Swift tonight. It does seem pretty interesting. I'm going to dive into it some more. Thanks for the recommendation! I am for sure now Swift-curious
@isodoubIet
@isodoubIet 6 місяців тому
@@NamanGoel34 Swift's syntax is weird/crazy though. Function parameters have an inside and an outside name, callback parameters spill past the function call, explicitly annotated exceptions everywhere, etc. I have my gripes with go but nothing in it is as crazy as swift's syntax.
@NamanGoel34
@NamanGoel34 6 місяців тому
@@isodoubIet 1. By default parameters have the same name inside and outside. And named parameters are an upgrade over position based upgrades. 2. The curly brackets *outside* the parenthesis is a little weird at first, but actually turns out to be super nice in the long run. Also, it’s optional so you can just not do it in your own code. 3. Explicitly annotated exceptions? There are no exceptions in Swift. Don’t quite get this one. Overall, fair that Swift’s syntax is a bit weirder than Go. But it’s simpler than Rust, which is full of cryptic symbols and shortened names. Swift is very readable after you learn its couple of idiosyncrasies.
@TimUckun
@TimUckun 6 місяців тому
Look at crystal and crystal macros. Crystal is a very nice language.
@victorpinasarnault9135
@victorpinasarnault9135 6 місяців тому
Hey primegean, have you seen Idris programming language? (Type drive development)
@clementdato6328
@clementdato6328 6 місяців тому
Loving Idris, but tbreal Prime doesn’t like/care about Haskell, and Idris is even more academy-focused, so probably he won’t like it a lot.
@victorpinasarnault9135
@victorpinasarnault9135 6 місяців тому
@@clementdato6328 maybe, but the conceptual design brought by that is really interesting.
@victorpinasarnault9135
@victorpinasarnault9135 6 місяців тому
And another language inspired by Swift is Hylo programming language, formely Val programming language, wich have mutable value semantics and the types are integers.
@AnthonyKenedy
@AnthonyKenedy 4 місяці тому
cool video)
@antonpieper
@antonpieper 6 місяців тому
I do wonder how swift compares to the other languages. With these features I kind of don't get why it is not as widely adopted
@fenixfve2613
@fenixfve2613 6 місяців тому
Because everything works well only on the Apple platform
@andrewdunbar828
@andrewdunbar828 6 місяців тому
They don't seem really that serious about Swift on non-Apple platforms.
@ConernicusRex
@ConernicusRex 6 місяців тому
Mostly it’s because of the opposite of fanboyism. Since it’s mostly used in the Apple ecosystem, people who don’t like Apple for whatever legitimate or illegitimate reason they have will immediately sh*t-talk it the same way they do with Apple hardware without ever actually exposing themselves to it.
@perc-ai
@perc-ai 6 місяців тому
they never tried to brand it outside of anything apple related so the community doesnt really care about its widespread adoption outside of macos
@NamanGoel34
@NamanGoel34 6 місяців тому
@@andrewdunbar828They’ve been taking Swift on Linux pretty seriously and working to make it a good server language. Windows support has been an afterthought for the most part.
@f.artemenkov
@f.artemenkov 4 місяці тому
Unfortunately, Swift still inconvenient when you try use pointers. It so simple and effective thing in C++, but in Swift it complete terrible.
@robonator2945
@robonator2945 6 місяців тому
1:00 prime once again provin he's living back in June 2021
@kira.herself
@kira.herself 6 місяців тому
I never knew that Swift looks so similar to Rust whoa
@hasithamapalagama3810
@hasithamapalagama3810 6 місяців тому
Swift is the best thing Apple created.
@ConernicusRex
@ConernicusRex 6 місяців тому
It’s open source and created by Lattner, creator of the LLVM. Not apple.
@mlfboys
@mlfboys 6 місяців тому
@@ConernicusRex Dawg Lattner worked at Apple, it was developed by Apple employees and announced at Apple’s WWDC. The initial released wasn’t even open source
@SilisAlin
@SilisAlin 6 місяців тому
@@ConernicusRexSwift initially was closed source and it’s backed by Apple
@Atr0sity
@Atr0sity 6 місяців тому
Please learn swift!!
@salvatoreshiggerino6810
@salvatoreshiggerino6810 6 місяців тому
Is it still not possible to have generic protocols?
@SilisAlin
@SilisAlin 6 місяців тому
You can. It’s called associated type. Been around for a long time
@ConernicusRex
@ConernicusRex 6 місяців тому
Quite literally has never been impossible. Associated Type has been part of Swift’s protocol system since the beginning.
@miracleinnocent2649
@miracleinnocent2649 6 місяців тому
Are we advertising for Go
@youtubeceoruinedyoutube
@youtubeceoruinedyoutube 6 місяців тому
Comptime isn’t a “macro-like system”. It’s just constexpr
@RafalMankaPL
@RafalMankaPL 6 місяців тому
seems to me like you want to try kotlin
@JamesPower
@JamesPower 3 місяці тому
Kotlin is nice, but Swift is a lot nicer (Kotlin’s tooling is better)
@Kiyuja
@Kiyuja 6 місяців тому
it turns MacOS into MacrOS
@jouebien
@jouebien 6 місяців тому
it's grate till you have to go back to objective C to do something.
@SilisAlin
@SilisAlin 6 місяців тому
For exactly what?
@stevenhe3462
@stevenhe3462 6 місяців тому
Swift is a cool language but the Apple ecosystem uh…
@Art-is-craft
@Art-is-craft 4 місяці тому
Yeah Apple did develop it and put a pile of money into it.
@Tony-dp1rl
@Tony-dp1rl 6 місяців тому
These videos where people passionately discuss languages used by less than 5% of the industry as if they matter are a lot of fun. :)
@clementdato6328
@clementdato6328 6 місяців тому
5% is a huge threashold, or we are not living in the same world.
@rocstar3000
@rocstar3000 6 місяців тому
9:36 Imagine using a language that is called "Objectively you're seeing PP's"
@mateuszdworak1252
@mateuszdworak1252 6 місяців тому
Swift is great, but iOS SDK is moronic sometimes, and Xcode is *always* dogwater
@skrundz
@skrundz 6 місяців тому
Swift was cool and had potential when Chris was still maintaining it. But now that apple booted him out and said they refuse to remove the objc runtime dependency on apple platforms, its dead to me
@JamesPower
@JamesPower 3 місяці тому
He left his role, he wasn’t fired. Foundation in Swift is a thing, at least. The objc runtime on Apple platforms seems necessary considering it needs to interop with objc and the system libraries.
@vince14genius
@vince14genius 3 місяці тому
Chris is still on the Swift open source team
@andrewcrook6444
@andrewcrook6444 6 місяців тому
Objective C uses a messaging based OOP model like smalltalk whist objective C++ uses the more C++ method based approach. Objective C started off as a pre-processor to the C compiler as did C++ iirc. Regarding C++’s OOP I don’t think it’s that good I haven’t used it for a while back then it was messy and wasn’t a complete implementation when you look at languages like Eiffel or Java even.
@SimonFreePlus
@SimonFreePlus 6 місяців тому
This is not correct. Objective-C++ is just Objective-C but with access to C++ language features because the clang compiler is in C++ mode as well as Objective-C mode. It doesn’t change anything about how Objective-C classes and message passing works, it just allows you to access C++ APIs and types from within Objective-C code, or store C++ class instances (etc) as instance variables in Objective-C classes (with the compiler emitting correct constructor/destructor calls in tandem with Objective-C object lifecycle calls. In industry, Objective-C++ (denoted by files that end in .mm instead of .m) is most often used to write Objective-C wrappers around a core of C++ code that is written to perform a task more efficiently than can be achieved using Objective-C alone due to its reliance on heap objects and dynamic dispatch for everything.
@ConernicusRex
@ConernicusRex 6 місяців тому
@@SimonFreePlusnailed it 🔥
@FaZekiller-qe3uf
@FaZekiller-qe3uf 6 місяців тому
I hate HTML templating in any language. I just want my HTML to be HTML and my code to be my code.
@Unavailable8923
@Unavailable8923 3 місяці тому
"...supports...macOS and Linux, with Windows support coming soon." ... Windows is always a 2nd class citizen in the world of Swift which is understandable given where it comes from, but in the context of gamedev, this is the biggest anti-feature you could have.
@5erTurbo
@5erTurbo 6 місяців тому
Kotlin pretty much had all of those stuff for ages
@imacuser101
@imacuser101 6 місяців тому
Clocks are still not fun in swift 😅
@hanamichi-sakuragi
@hanamichi-sakuragi 6 місяців тому
Try out Haskell please
@keenoogodlike
@keenoogodlike 6 місяців тому
Even though it better than Rust, As long as it force you to work for Apple platform only, nope.
@NamanGoel34
@NamanGoel34 6 місяців тому
Works on Linux just fine.
@ConernicusRex
@ConernicusRex 6 місяців тому
It’s been multi platform for years.
@keenoogodlike
@keenoogodlike 6 місяців тому
@@ConernicusRex If you intend to develop your app for multiple platforms, you'll need to create separate codebases. I rather use Flutter.
Vlang: The language of 2023?? | Prime React
35:53
ThePrimeTime
Переглядів 127 тис.
Interview With A Sr JavaScript Dev | Prime Reacts
24:43
ThePrimeTime
Переглядів 118 тис.
Зомби Апокалипсис  часть 1 🤯#shorts
00:29
INNA SERG
Переглядів 4,2 млн
Python vs Swift | Chris Lattner and Lex Fridman
11:16
Lex Clips
Переглядів 146 тис.
100 Seconds of Rust | Prime Reacts
10:38
ThePrimeTime
Переглядів 297 тис.
Can Swift Replace Bash (for Scripting)? | @SwiftBird
20:18
The Swift Bird
Переглядів 1,7 тис.
Rabbit R1 Is Just An Android App..
12:27
ThePrimeTime
Переглядів 81 тис.
Why I Quit Netflix
7:11
ThePrimeagen
Переглядів 473 тис.
MAXIMUM CRINGE Programming Language Tier List | Prime Reacts
22:45
ThePrimeTime
Переглядів 451 тис.
Server Side Swift Using Vapor Part 1 - Getting Started
14:37
azamsharp
Переглядів 6 тис.
Pkl: Apple's New JSON/YAML Killer (I actually want to use this...)
14:30
Theo - t3․gg
Переглядів 341 тис.
Big Tech AI Is A Lie
16:56
Tina Huang
Переглядів 56 тис.
''Бесплатные умные'' домофоны для глупых людей. За чей счет банкет?
12:48
Вадим Шегалов.Оккультные игры элиты
Переглядів 32 тис.
СМАРТФОНЫ HTC ВЕРНУЛИСЬ В 2024! Шок для Apple, Samsung и Xiaomi...
11:51
Thebox - о технике и гаджетах
Переглядів 27 тис.
It's embarrassing how much I like this thing.
12:19
Linus Tech Tips
Переглядів 933 тис.
Как открыть дверь в Jaecoo J8? Удобно?🤔😊
0:27
Суворкин Сергей
Переглядів 938 тис.
Крутое обновление microReader!
5:54
Заметки Ардуинщика
Переглядів 24 тис.