catatp.fm Unofficial Accidental Tech Podcast transcripts (generated by computer, so expect errors).

205: People Don't Use the Weird Parts

A surprisingly deep dive into Swift, now that one of us is finally using it.

Episode Description:

Transcript of this episode

Sponsored by:

  • Audible: With Audible, you’ll find what you’re looking for. Get a free 30-day trial.
  • Eero: Finally, Wi-Fi, that works. Use code ATP for free expedited shipping.
  • Squarespace: Build it beautiful. Use code ATP for 10% off your first order.

Become a member!

MP3 Header

Chapters

  1. Intro
  2. LLVM and Bitcode
  3. Sponsor: Squarespace (code ATP)
  4. Management
  5. Origin of Swift
  6. Launch
  7. Swift use by Apple
  8. Transitional feelings
  9. Sponsor: Eero (code ATP)
  10. Open-sourcing
  11. Server-side Swift
  12. Low to high, easy to hard
  13. Sponsor: Audible
  14. Influences
  15. Why adopt now?
  16. Style and idioms
  17. Rust-style memory model?
  18. Swift in the browser
  19. ABI stability
  20. Leaving it in good hands
  21. The shoemaker’s language
  22. Dynamic features
  23. Community influence
  24. RxSwift
  25. GC vs. ARC
  26. Ending theme
  27. Post-show: Making splinters
  28. Post-show: Neutral

Intro

⏹️ ▶️ so let’s start with some follow up why did chris lattner decide to leave apple

⏹️ ▶️ last week we talked about this and we tried to list all the reasons we could think of why he

⏹️ ▶️ might be leaving um and i think we covered most of the major threads of speculation

⏹️ ▶️ and we didn’t really get a lot of listener feedback about it anybody did reply was mostly voting for one of the things we talked about

⏹️ ▶️ um but here’s the thing of this topic unless there’s some kind of like secret doomsday

⏹️ ▶️ a thing about apple that only chris knows it’s not actually that important that we figure out like

⏹️ ▶️ why he left apple or like what was in his heart of hearts like aside from just us being busy bodies or just wanting to

⏹️ ▶️ know like gossip type stuff um and second pragmatically speaking

⏹️ ▶️ this is just not the type of thing that people who leave apple talk about or you know if they do talk about it it’s

⏹️ ▶️ like years and years later after no one cares any more or you know like it’s it’s not a big deal

⏹️ ▶️ so even if there was some deep dark reason it’s not like we would know about it until years from now and honestly

⏹️ ▶️ the straightforward boring explanation is probably the right one anyway so you know i don’t know what

⏹️ ▶️ do you think chris this sounds about right to me john

LLVM and Bitcode

⏹️ ▶️ would you ever buy an electric car in white you

⏹️ ▶️ are such a jerk why are you so mean to me marco no no i’m a fan

⏹️ ▶️ of red cars there you go yellow if i could get them yellow that’s bold makes

⏹️ ▶️ all right we we obviously need to talk about what’s happening right now so a t p

⏹️ ▶️ is not in an interview show but in extraordinary circumstances

⏹️ ▶️ weird things can happen and so in today’s episode we have an extraordinary

⏹️ ▶️ circumstance a former apple employee chris ladner was let nice enough to join

⏹️ ▶️ us on the show and so this is going to be three people interviewing one person which is

⏹️ ▶️ to say the least a bit peculiar and it’s something that we’ve never really done before so this

⏹️ ▶️ could be a little bit of a rough ride but we’re going to try to make our best of it and

⏹️ ▶️ and i’ll just say right up front thank you so much chris for coming on the show and we definitely appreciate

⏹️ ▶️ it to kind of kick all this off would you mind giving us like a nickel tour of who is chris lattner

⏹️ ▶️ okay well i can try i’m a programmer i

⏹️ ▶️ love coding i have for a long time i am most

⏹️ ▶️ widely known for starting vm and getting it off the ground and handing it off to other smarter

⏹️ ▶️ people i started clang which is the case plus plus object to see compiler and likewise

⏹️ ▶️ got it to the point where it was thriving and then let other smarter people run

⏹️ ▶️ it and then started swift and got swift going and it recently got

⏹️ ▶️ past three toto and it has an amazing community and it has a great team of people running

⏹️ ▶️ it and now i’m ready to jump to the next thing and so i guess the short version

⏹️ ▶️ of what i’d like to do is tackle really hard problems and do things

⏹️ ▶️ that most people think are impossible so we’re going to go back in time a little bit

⏹️ ▶️ and i hope that you could tell us how you ended up coming to apple like if you can

⏹️ ▶️ remember back that far like you started before you were at apple right so how

⏹️ ▶️ did you how did you end up at apple yeah great question so i started working at lm at the university

⏹️ ▶️ of illinois it was a research project and the

⏹️ ▶️ it really was kind of hoped for and designed to be

⏹️ ▶️ fully general and production quality and all those great things that you’d want as a graduate student

⏹️ ▶️ for people to use your code but it also wasn’t it was

⏹️ ▶️ had a lot of the great architectural ideas maybe but it wasn’t fully baked it wasn’t

⏹️ ▶️ it wouldn’t solve all the world’s problems and by

⏹️ ▶️ the time i got to graduate the question was what do i do next and of course my dream was

⏹️ ▶️ continue pushing it forward and build it out to be something real and to do that i would have to go

⏹️ ▶️ to a place that would allow me to work on it and i was really fortunate to have build some relationships with

⏹️ ▶️ folks at apple and they took a chance on me and i jumped to apple and started building out

⏹️ ▶️ vm’s my job it was it was totally a dream of mine so that’s how i got to graduate

⏹️ ▶️ did you get your degree and then go to apple yeah yeah well that was nice otherwise

⏹️ ▶️ how do you ever get a job yeah you can’t get a job with that degree we all know that now

⏹️ ▶️ so how would you explain lvm to somebody who doesn’t know stuff about compilers cause

⏹️ ▶️ like we all just rattle off you know l vm compiler building toolkit or whatever like but

⏹️ ▶️ how would you explain that to someone design all of our listeners of programmers who isn’t intimately familiar with

⏹️ ▶️ how compile it works sure so and at first we start with what is a compiler a compiler

⏹️ ▶️ is the thing that takes the code that a programmer writes and turns it into something

⏹️ ▶️ the machine can understand and so there’s lots of different kinds of computers with lots of different kinds

⏹️ ▶️ of processors most programmers don’t want to have to think about that or know about that

⏹️ ▶️ and they want to program and think at a much higher level than what the actual processor

⏹️ ▶️ can do and so the compiler’s job is to transform what what the human wrote and

⏹️ ▶️ to something the machine could understand then lvm is a

⏹️ ▶️ modular system for building different kinds of compilers because there’s lots of different reasons

⏹️ ▶️ why people would want to use compiler technology and i think lvm was most successful over

⏹️ ▶️ the years because it was built as reusable components a kind of like a framework

⏹️ ▶️ and then the framework can be used to solve lots of different problems and one of the fun things

⏹️ ▶️ about lvm is that it was eventually over the years used to solve problems that we had never even imagined

⏹️ ▶️ which is really exciting so one example of that the type of problem is

⏹️ ▶️ i remember from past w w d c s the idea that the xcode i d

⏹️ ▶️ the gooey that you programmers use to make their applications that very often in that guy

⏹️ ▶️ you need to do things that have an understanding of the code but when the compiler is a

⏹️ ▶️ big maiti thing the best you can kind of do is compile everything in the background and spit out some stuff but

⏹️ ▶️ when it’s a modular toolkit you can take those pieces and just use the part that

⏹️ ▶️ understands like the syntax tree or whatever and integrate them was that the first use

⏹️ ▶️ of lm is something other than like you know a compile like a straight up compiler

⏹️ ▶️ that you just point to at your code and produces output like you know in other words integrating it into

⏹️ ▶️ applications or was there some use before that but i think that the first use in production

⏹️ ▶️ was in the open jail stack which ended up shipping in a late software update

⏹️ ▶️ for tiger as well as in leopard which was ten four and

⏹️ ▶️ ten to five um there it was used in a completely invisible way to translate

⏹️ ▶️ to basically repack data and upload it to the gpu and so when you need

⏹️ ▶️ to when you’re making open jail calls to say g vertex tri or

⏹️ ▶️ whatever the low level jail call is those vertices need to be

⏹️ ▶️ transformed into a very specific data format the g p can understand and you have a whole bunch of different

⏹️ ▶️ kinds of calls that can be used to produce for text or other geometry data but

⏹️ ▶️ you also have a matrix of different kinds of chips you need to support and they all have different formats

⏹️ ▶️ and different capabilities and requirements and so lvm was used to generate very small chunks of code to do

⏹️ ▶️ that and it was part of the sixty four bit bring up in the leopard timeframe and so that

⏹️ ▶️ was probably the first completely invisible use of it that used and proved

⏹️ ▶️ a lot of the kind of cogeneration technologies so forget me one

⏹️ ▶️ more unrelated things we’re going to go from what is a compiler all the way down to nitty gritty stuff

⏹️ ▶️ here my vague recollection of what you just described the whole video driver thing was that

⏹️ ▶️ there were files on disk in the shipping o s that were basically lvm bytecode like

⏹️ ▶️ these little b c files and they would get slurped up and converted

⏹️ ▶️ to machine code appropriate for the gp and the sp is that am i right about that yeah yeah you’re

⏹️ ▶️ absolutely right and so basically the way to look at is the the bit code files

⏹️ ▶️ the lm the shipped with the os were little snippets of code that then at

⏹️ ▶️ runtime were recombined and optimized across and so that was the library of primitives

⏹️ ▶️ that the open jail runtime used to assemble what it was trying to do

⏹️ ▶️ all right so my question about this and maybe you kind of alluded to it with either a slip of the tongue or a revealing

⏹️ ▶️ understanding is what is the difference between vm bytecode and what apple currently brands

⏹️ ▶️ as bit code oh well are you asking for historical q is this a historical

⏹️ ▶️ question it’s a technical and historical cause i’m confused by the branding and i’m also confused

⏹️ ▶️ by the tech so vm prior to lvm todaro

⏹️ ▶️ in these version numbers of the open source version numbers not related to the apple version numbers and they’re

⏹️ ▶️ confusingly different for not very interesting reasons but before todaro

⏹️ ▶️ i used a really horrible encoding in binary that

⏹️ ▶️ was branded bytecode because that’s what java used it had a whole bunch of problems and that it wasn’t

⏹️ ▶️ extensible it was fragile lvm was changing

⏹️ ▶️ it didn’t have compatibility and so in the elan two

⏹️ ▶️ date time frame which gosh is probably i don’t know ten ten

⏹️ ▶️ years ago or more it’s been a long time ago now um uh i

⏹️ ▶️ redesigned the whole thing and it now uses this one bit code format and used it bit code

⏹️ ▶️ as a term for two reasons one of which was it was different than byte code and so the two could live

⏹️ ▶️ side by side in the directory tree for a while and the second reason is that the encoding is a bit

⏹️ ▶️ stream format instead of a bit stream but that that’s the origin of the term bit

⏹️ ▶️ code you can find documentation on the file format is actually a very general

⏹️ ▶️ encoding format you can use for xml type purposes it’s a self describing file

⏹️ ▶️ format and multiple different things can be encoded in bit code yeah there was definitely

⏹️ ▶️ some confusion about that because when apple presented it when they presented it as like the required was like the watch apps have

⏹️ ▶️ to be in bit code marco you would know this watch is required i s is still optional

⏹️ ▶️ yep and t v s required and they would have you send you put your stuff in bit code and

⏹️ ▶️ there was a lot of speculation early on about what that meant like in terms

⏹️ ▶️ of does that mean that what you’re uploading is not a finished binary and therefore

⏹️ ▶️ it’s like this machine agnostic and could be targeted at any cpu and the more prosaic

⏹️ ▶️ version like it doesn’t mean that cpu agnostic all it means is that

⏹️ ▶️ apple has slightly more freedom to like change instructions on the cbs they do

⏹️ ▶️ target how would you characterize the what what what advantages are there

⏹️ ▶️ of a compiling something to bit code and then uploading it somewhere versus sending

⏹️ ▶️ someone a binary sure there’s there’s a couple of different advantages for that one of which is that

⏹️ ▶️ the compiler keeps getting better and so if the compiler learns a new optimization it can be applied

⏹️ ▶️ to existing applications without app app developers having to re upload their their ap

⏹️ ▶️ that’s one small thing um other things are that apple does periodically add

⏹️ ▶️ new instructions to its cpus one example of this historically was

⏹️ ▶️ the uh the hilariously named swift chip that it launched which

⏹️ ▶️ was the first designed in house thirty two bit arm chip this was

⏹️ ▶️ the iphone five if i recall it so in this

⏹️ ▶️ ship they added an integer divide instruction and all the chips before that didn’t have the ability to do

⏹️ ▶️ an integer divide in hardware you had to actually open code it and there’s a library function to do that

⏹️ ▶️ and so that and a few other instructions they added were a pretty

⏹️ ▶️ big deal and used pervasively and the only way to tackle that and handle that and

⏹️ ▶️ use it effectively was to introduce an entire new slice and so if you are an apt velop back then

⏹️ ▶️ you had the v seven slice which was all the older ships and then you had a visa s

⏹️ ▶️ slice as for swift which was the slice

⏹️ ▶️ that included the integer divide now this is a pain for app developers it’s a pain for apple

⏹️ ▶️ everybody has it has to convinced all the developers to take it seriously and if it doesn’t if app developers don’t support

⏹️ ▶️ it then the new hardware doesn’t benefit from it and so bit code allows that kind of thing to go

⏹️ ▶️ completely away so if bit code apple can just recompile the applications in the store and

⏹️ ▶️ say ha ha this this device has an integer divide instruction and it works

⏹️ ▶️ perfectly with the thinning kind of architecture they have for deploying resources to specific

⏹️ ▶️ device types and it all kind of plugs together um bit code is

⏹️ ▶️ not a magic solution though it doesn’t you can’t take a thirty two bit app for example

⏹️ ▶️ and run on a sixty four bit device that that kind of portability isn’t something that i could can give you

⏹️ ▶️ notably because that is something that’s visible on c and so as you’re writing

⏹️ ▶️ sea code you can write if death you know pointer size equals thirty two and that’s something

⏹️ ▶️ that bit code can’t abstract over and um so it’s useful for very

⏹️ ▶️ specific low level kinds of enhancements but it isn’t a panic that

⏹️ ▶️ makes everything magically portable at the same thing i would assume for like architecture changes especially if

⏹️ ▶️ there was an indian difference because indian this is visible from the sea world so if you can’t you can’t target different indian ness

⏹️ ▶️ yep yeah so it’s it’s not something that magically solves all portability problems but it is very useful

⏹️ ▶️ for specific problems that apples faced in the past and that going back to the the slice thing that’s

⏹️ ▶️ like terminology like the maco format where you get to put different architectures worth of executables or

⏹️ ▶️ is that a different yeah i think the technology that goes all the way back to next when next supported

⏹️ ▶️ really heterogeneous different architectures like p a risk and and spark and

⏹️ ▶️ paris and intel all back in the next days and it allows you to

⏹️ ▶️ compile your application with multiple slices they call them and then there’s a

⏹️ ▶️ tool called lipo which sticks them together and um at runtime

⏹️ ▶️ the os picks the slice that best matches your cpu in practice and so an app developer

⏹️ ▶️ can support many different kinds of architectures and then the os just does the right thing

⏹️ ▶️ and so in today’s world is very common to build an ios app for example

⏹️ ▶️ for both arm sixty four and arm thirty two in the way that works in the native

⏹️ ▶️ in the simplest cases it’s just two different binaries that are stuck together

⏹️ ▶️ and then the os picks the right one to run all right i could go over this river but i don’t want to

⏹️ ▶️ get on this right hole it’s just there’s there’s some penton requesting about bit

⏹️ ▶️ code and bite cob but now i feel satisfied if we can move on to broader topics

⏹️ ▶️ were sponsored to night by square space

⏹️ ▶️ squarespace dot com and use code at to get ten percent off your first purchase it’s the

⏹️ ▶️ new year you might have a new project you might have a new goal you want to reach and that might involve making

⏹️ ▶️ a website make your next move with a beautiful website from squarespace

⏹️ ▶️ squarespace sites are so incredibly easy to make and they are incredibly beautiful

⏹️ ▶️ and the tools are very powerful this is a great combination that i personally have never seen before

⏹️ ▶️ in the web building space until square space the amount of power you get with these tools

⏹️ ▶️ is just incredible you can make so many different kinds of sights with so little effort nothing

⏹️ ▶️ else comes close your sights look professionally designed regardless of your skill

⏹️ ▶️ level with no coding required although if you want to jump in and alter some of the code you actually can

⏹️ ▶️ but you don’t have to and it probably isn’t a good use of your time because square space is such a great

⏹️ ▶️ platform right out of the box whether you’re making website for you or for somebody else

⏹️ ▶️ if you make up for somebody else square space is the place you want to do that because you shall

⏹️ ▶️ them how to use square space and then you’re done they’re not coming to you any more squarespace will support it if

⏹️ ▶️ they need help and they’re able to figure things out on their own because it’s just so much easier to use than what ever seem as you were going to

⏹️ ▶️ install on their server so check it out today go to square space dot com use code at

⏹️ ▶️ to get ten percent off your first purchase when you decide to sign up

Management

⏹️ ▶️ whether you’re making a sight for you or somebody else make your next move with square space

⏹️ ▶️ so chris how was your transition

⏹️ ▶️ from coding to being a manager because from an outsider’s point of view it looked like you know you

⏹️ ▶️ had arrived at apple you you were working heavily on l v m like you had said earlier but over time i

⏹️ ▶️ mean even just looking at the resume on your website it seems pretty clear that you are doing a lot more managing

⏹️ ▶️ lately than perhaps coding or maybe maybe just worked around the clock that wouldn’t

⏹️ ▶️ surprise me either but how how would you how did you feel about your transition from from

⏹️ ▶️ being just a code monkey to being a manager and i ask in part because at my phase of

⏹️ ▶️ my career i am still a code monkey but i think it’s not too far away that i might become a manager and

⏹️ ▶️ so i’m curious to hear you know from from one code monkey to another how did that transition

⏹️ ▶️ go and what did you learn from it yeah that’s kind of interesting so i don’t think it is

⏹️ ▶️ a hard transition i’m still writing code i still love writing code that’s something

⏹️ ▶️ that i think is a key part of my identity

⏹️ ▶️ but on the other hand it is very strange so i started managing people at apple

⏹️ ▶️ really pretty early on maybe a year or so after i joined i started

⏹️ ▶️ managing two or three people because i was kind of the best person to

⏹️ ▶️ to manage the natan lvm effort at the time and

⏹️ ▶️ initially it was mostly just being a tech lead and so if you’re

⏹️ ▶️ if you’ve ever driven a project where you have co workers that don’t report to

⏹️ ▶️ you but you’re kind of guiding them and helping make technical decisions that that’s where

⏹️ ▶️ it started over time i my team grew and eventually

⏹️ ▶️ i ended up picking up and running kind of a second level manager role where you’re managing other

⏹️ ▶️ managers and each step along the way it introduces new challenges and along

⏹️ ▶️ the way i told myself that um managing is something that i

⏹️ ▶️ had to do because i was the best qualified to do it and i didn’t want anybody else to

⏹️ ▶️ and that coding was my real joy and passion and i think the coating really is my joint

⏹️ ▶️ passion but along the way looking back i’ve realized that i am actually pretty good at managing

⏹️ ▶️ and i really do like building teams i like working with people and

⏹️ ▶️ i’ve never considered myself to be a people person which is you know it’s just very

⏹️ ▶️ very odd for me to even think about that but i actually do understand how people

⏹️ ▶️ work and can you know really care about getting the most out of people and working with

⏹️ ▶️ them to make them successful and so it’s been kind of a transition

⏹️ ▶️ over time but i’ve always hung on to coding and even though i have a full time management job

⏹️ ▶️ id code like crazy in nights and weekends and i’m not the kind of guy that likes to sit

⏹️ ▶️ around idle and and so i’ve always just been busy

Origin of Swift

⏹️ ▶️ so i mean you can get into as much of this history as you want to crisp but ah how did you

⏹️ ▶️ get swift to happen inside apple because from the outside it’s mysterious

⏹️ ▶️ to us how big important projects come to be like

⏹️ ▶️ you know what you name the headlining things that have come on of apple we hear that apple does

⏹️ ▶️ a lot of things that don’t see the light of day how did you get probably one of the biggest things

⏹️ ▶️ ever to come out of apple an entirely new language created in house how did you get that to happen and

⏹️ ▶️ not just be some little thing that was off to the side that fizzled off and disappeared sure well so i can

⏹️ ▶️ tell you about swift but i don’t think you should project this onto every other project at apple because

⏹️ ▶️ i’m sure they’re all different so i can just talk about my experiences so swift started

⏹️ ▶️ in two thousand ten um you know it’s kind of the

⏹️ ▶️ timing is suspicious because it’s right after a blogger wrote something about how apple

⏹️ ▶️ needed a new programming language i’m not a blogger okay or

⏹️ ▶️ i wasn’t a thing i was not a blog that was the prestigious website

⏹️ ▶️ still i

⏹️ ▶️ i don’t remember if i read it exactly then that that was a causal

⏹️ ▶️ link to starting working on swift or if it was just because i had just

⏹️ ▶️ finished up clancy plus plus support and we’d launch clancy plus plus and of course if

⏹️ ▶️ you write see plus plus good you know how ugly and horrible it is but if you implement c plus plus

⏹️ ▶️ it’s a whole nother level of challenge and so getting that first release

⏹️ ▶️ out was it was a major accomplishment for the entire team and it was a major major effort

⏹️ ▶️ for a ton of people involved and as is typical you get something over

⏹️ ▶️ the finish line and of course it wasn’t fully finished it let alone was to go but a lot of the

⏹️ ▶️ intellectually interesting to me at least pieces were were done that’s when i started thinking

⏹️ ▶️ about okay well what comes next and then implementing other people’s stuff

⏹️ ▶️ like for example to see the c plus plus the object to see standards and languages

⏹️ ▶️ but there were there were you know things that we weren’t happy with and things

⏹️ ▶️ i wasn’t happy with and so swift started out as just a let’s let’s see

⏹️ ▶️ what could be done right let’s see what a much simpler language that doesn’t need a preprocessor

⏹️ ▶️ doesn’t need tri graphs doesn’t need all all the weird things that have accumulated into

⏹️ ▶️ sea and see plus plus over the years let’s see what we can do and am just

⏹️ ▶️ try to build something nicer um initially it was really just a me

⏹️ ▶️ me messing around and nobody knew about it because it wasn’t anything to know about u

⏹️ ▶️ but eventually it got a little bit more serious and said hey well after

⏹️ ▶️ playing around a little bit i think that this actually could make sense and so i started talking to

⏹️ ▶️ my management i started talking to some of the engineers that were working on clang

⏹️ ▶️ and they seemed excited about it we got a couple of people working on it part time

⏹️ ▶️ and i commenced my manager that it was interesting enough that we could have

⏹️ ▶️ a couple of people work on it now this wasn’t a major commitment this was

⏹️ ▶️ a okay well let’s see see what there is here and that started a

⏹️ ▶️ conventional demo schedule and other things where we set milestones in place and tried to

⏹️ ▶️ to justify the investment that was being put into it eventually got to the

⏹️ ▶️ point where there was it was part of the long that it was posing strategic

⏹️ ▶️ questions so the strategic questions were of the form okay we have objective

⏹️ ▶️ c objectives is a great language it is probably

⏹️ ▶️ directly responsible for the iphone being successful because

⏹️ ▶️ it’s really high performance it allows you to get your job done in and supports

⏹️ ▶️ high level frameworks in beautiful way there’s a ton of stuff to love about objective sea and while

⏹️ ▶️ there are few things that are ugly about it some at signs and semi corns and other stuff like that you know we can

⏹️ ▶️ make objects better and so the question was always why not just make

⏹️ ▶️ objects better right why don’t we just keep evolving objectives and why do we want to face

⏹️ ▶️ potential disruption in terms of moving the entire development community to something

⏹️ ▶️ new and we kicked that around for a long time we talked about both sides and we came

⏹️ ▶️ to realize that yes we can and should make objectives better and we continued to invest

⏹️ ▶️ in objectives we did things like arc for example which is a major effort

⏹️ ▶️ but we got dot well so dot syntax predated this

⏹️ ▶️ yeah dot dot syntax so the objectives two features and the block syntax

⏹️ ▶️ were all kind of prior to this i worked on blocks but um but it wasn’t

⏹️ ▶️ in this time for him and so we were talking about okay well can we just make objects

⏹️ ▶️ better and can we feature creep it to the language that we want for the fullness of time because if we can that be much

⏹️ ▶️ less disruptive to the community and we decided that yeah we can we can move objectives

⏹️ ▶️ a lot closer to what we want so we can get automatic memory management with art for example but we

⏹️ ▶️ can’t ever take away the problems that lead to to objectives being

⏹️ ▶️ unsafe and the fundamental problem was objective see was built on top of sea an

⏹️ ▶️ c inherently has pointers it has unitized variables it has array

⏹️ ▶️ overflows it has all these problems that even if you have full control over your compiler

⏹️ ▶️ and tool stack you just can’t fix right to fix to fix dangling pointers you’d have to

⏹️ ▶️ fix lifetime issues and s c doesn’t have any framework to reason about that and retrofitting

⏹️ ▶️ that into a compatible way into the system just wouldn’t really work if you took away c from objective

⏹️ ▶️ set you couldn’t use a c rays on the stack for example and if you couldn’t

⏹️ ▶️ do that there’s entire classes of applications where the performance just wouldn’t be acceptable

⏹️ ▶️ and so we went round round round we said okay the only way that

⏹️ ▶️ this can make sense in terms of the cost of the disruption to the community

⏹️ ▶️ as if we make it a safe programming language which means not safe as in you

⏹️ ▶️ can have no bugs but safe in terms of memory safety while also providing high

⏹️ ▶️ performance and and moving the programming model forward and so that was really kind

⏹️ ▶️ of the ideas that they came together to make swift being worth the investment

⏹️ ▶️ and being worth being disruptive to the community so a lot of these kinds

⏹️ ▶️ of pitches and ideas were being held in very small

⏹️ ▶️ small small meetings and coming out of w

⏹️ ▶️ c twenty thirteen is when we and the executive team decided okay let’s

⏹️ ▶️ really commit to this and that’s coming out of w c twenty thirteen is when the developer tools

⏹️ ▶️ team i came to know about it and really started working hard on it and swift

⏹️ ▶️ as swift as a huge huge effort by hundreds of people and

⏹️ ▶️ that’s when all the work on bring up the debugger and the id support and playgrounds

⏹️ ▶️ and all the other things that they charged him to swift one otto really started coming together and and

⏹️ ▶️ make happen so it’s kind of how swift came to be is again one

⏹️ ▶️ step after another building small things explaining to people why it makes sense

⏹️ ▶️ why it was worth it and then also i think that a major important aspect of

⏹️ ▶️ swift being i guess worth taking a risk on was that we

⏹️ ▶️ i told people that we would not guarantee source compatibility in one data

⏹️ ▶️ and that that was really interesting because that actually was a

⏹️ ▶️ big relief for people because internally that meant that it didn’t have to be perfect

⏹️ ▶️ when it launched it meant that we could learn we could adapt and that as long as we

⏹️ ▶️ were clear with the community about that that that would allow us to get to ultimate greatness

⏹️ ▶️ and learn from actual usage in practice and i think that was a really key piece

⏹️ ▶️ to a swift coming and actually making it to the market so strategically

⏹️ ▶️ speaking when you were doing like the work on to improve objective

⏹️ ▶️ c see did you have in mind the ability to potentially leverage

⏹️ ▶️ some of that work for swift like like i’m trying to think like the strategy of how you get it done like part of

⏹️ ▶️ it is personal relationships and like knowing the right people part of it is persuasion you have to persuade them with

⏹️ ▶️ your technical arguments and your business arguments and stuff like that but then part of it was part of it also

⏹️ ▶️ a laying the groundwork with with efforts and technologies that have

⏹️ ▶️ multiple uses yeah absolutely so so one great example of that is ok um

⏹️ ▶️ it was really clear to me that if we were to get to memory safety we had to have automatic memory management

⏹️ ▶️ and i don’t know if you want to go down the gc versus ark rabbit hole or not but

⏹️ ▶️ arc seemed like obviously the right model to me and and to some other people

⏹️ ▶️ and so we we said okay we need to get to an automatic memory management

⏹️ ▶️ model objectives isn’t because objectives at the time had the

⏹️ ▶️ garbage collector which had numerous problems and so we had to get

⏹️ ▶️ objectives to be memory managed and so that’s why arc was

⏹️ ▶️ became a thing it became a really high priority and i think that it’s a great example

⏹️ ▶️ of something that by itself had a huge amount of value to the object to see community and then

⏹️ ▶️ after that we had similar other efforts like modules for example that was a huge thing

⏹️ ▶️ that both improved build time but was also absolutely essential to enabling

⏹️ ▶️ in swift code to eventually just say import you like it and get everything and so there was

⏹️ ▶️ a number of things that rolled out over the years and it was really funny at the time because the

⏹️ ▶️ object developers externally and even internally to apple always accused the compilers and languages

⏹️ ▶️ team of taking objective on this random walk and they didn’t know how it all fit together and

⏹️ ▶️ where where is this strategy and why are you guys working on this and why aren’t you working on some other syntactic

⏹️ ▶️ sugar for the thing i want and of course we could never tell them but there was there was a good reason

⏹️ ▶️ and so in another example that is the object to see literals feature i think

⏹️ ▶️ we introduced that in twenty thirteen fico were for

⏹️ ▶️ ray literals and other things like that that that that was a interesting feature in that it was

⏹️ ▶️ a relatively small amount of engineering work that

⏹️ ▶️ brought objects the objects language much closer to swift in terms of having

⏹️ ▶️ a raise and dictionary literals as part of the language but the real reason

⏹️ ▶️ for doing it is that it was a small amount of work that moved to exy forward which allowed the compiler

⏹️ ▶️ language team to focus on swift because swift was a very

⏹️ ▶️ large amount of work and that was you know appeasing the community and

⏹️ ▶️ you know solving real problems but you know buying time to actually pour into

⏹️ ▶️ the multi year project of making swift language happen that’s when you pull out the syntactic sugar the programmers

⏹️ ▶️ love it take simplement here you go exactly everyone applauds when they see the slide

⏹️ ▶️ i mean in all fairness that was a really big deal

Launch

⏹️ ▶️ anyway so so kind of building on on the apple internal reaction thing um

⏹️ ▶️ you know this this language in its development and in its public release

⏹️ ▶️ is probably a fairly unique language in like the context in which it was released and you

⏹️ ▶️ have this this massive company i mean nobody probably had more observe the objective c programmers than

⏹️ ▶️ apple does and see if this massive company with tons of internal programmers and a massive internal

⏹️ ▶️ code base that is using this this other language you have this entire community

⏹️ ▶️ of i s and mac developers and then you have the entire

⏹️ ▶️ world watching every move apple makes and putting under very very heavy scrutiny so

⏹️ ▶️ the release of this language in this context is probably not only very high pressure but also like

⏹️ ▶️ unique in that you you knew that you were going to face a

⏹️ ▶️ lot of people up front like most languages probably start out with a few people using them you know some in some

⏹️ ▶️ random corner of the internet and eventually maybe some maybe it slowly takes off this was not that way

⏹️ ▶️ and so what considerations i guess went into that and also

⏹️ ▶️ how were you able to convince people even inside of apple to

⏹️ ▶️ to use swift and and how was how was that going

⏹️ ▶️ um so i guess there’s different answer to that for different

⏹️ ▶️ phases um we had no idea that the

⏹️ ▶️ reaction would be as strong and as positive as it was and so i think we were blown away and

⏹️ ▶️ caught unaware in some ways but

⏹️ ▶️ in other ways i think we did the right thing so for example if you look at swift

⏹️ ▶️ over time swift one and swift two are as similar to objective seas we can

⏹️ ▶️ make them so if you look at the way that selectors are named for example it was

⏹️ ▶️ very there’s a very direct correlation if you look at the way objective

⏹️ ▶️ or swift one was explained to people it was explained to people as

⏹️ ▶️ it’s just like objective c you can use all your same patterns you can use all the same

⏹️ ▶️ frameworks you can continue doing object in programming you can do all these things but it

⏹️ ▶️ also has some cool new things like enums and pattern matching and these other things and

⏹️ ▶️ so it’s great because it’s it’s just cleaned up syntax for what you already know plus it has some new

⏹️ ▶️ cool stuff that you can play with right and then you fast forward a year or two and the swift

⏹️ ▶️ community was really taking off it was people were understanding what swift was about

⏹️ ▶️ swift open sources also enabled this and swift three is really about swift

⏹️ ▶️ becoming its own language that was really true to itself and standing you know stands

⏹️ ▶️ by itself and that’s where you see the method calls in tax for example being radically

⏹️ ▶️ changed and a lot of things just kind of coming together and

⏹️ ▶️ really focusing and polishing the language in terms of

⏹️ ▶️ the the rise of the commun the external community and people using it

⏹️ ▶️ that was really really hard for us because um so my experience had

⏹️ ▶️ been with lvm and with clang clang as a s in c plus plus compiler an objective c

⏹️ ▶️ was completely different than swift because when we open

⏹️ ▶️ sourced and launched clang which was at apple um everybody

⏹️ ▶️ yawned we open source it very early on and people said

⏹️ ▶️ okay you’re nuts nobody can build a sequels plus compiler that’s that’s not a thing why are you

⏹️ ▶️ even messing around with this and you know we got one contributor to the project we and we had

⏹️ ▶️ no users and then we got you know a month later we might get another contributor another

⏹️ ▶️ person part time setting in patches and it was a very slow growth that um

⏹️ ▶️ that was ultimately really great because it was relatively low pressure

⏹️ ▶️ was swift and with the the way it was launched it was completely different because it went from

⏹️ ▶️ um nobody knowing about you everybody knowing about it overnight literally and

⏹️ ▶️ um there being so much excitement so many people that were nervous and had

⏹️ ▶️ bad reactions to other people that were super excited but a lot of people that were suddenly hitting bugs

⏹️ ▶️ and having challenges and problems and why did you do this and why didn’t you do that and you know

⏹️ ▶️ some of that was misguided just because they didn’t know swift yet but other other other

⏹️ ▶️ aspects were really spot on and that was when i really started learning about how people

⏹️ ▶️ were using and started iterating and moving swift and swift between the w

⏹️ ▶️ c launch and swift one auto release changed dramatically and

⏹️ ▶️ that was a really really hard time for the entire team because we really wanted to

⏹️ ▶️ get it as close as we could to what we wanted but we had a very short amount of time to do so

⏹️ ▶️ and um i think that’s been true for swift two and swift three as well where

⏹️ ▶️ we have really high goals for the team and really high goals for what we want to

⏹️ ▶️ get done and that makes it a lot a lot of pressure and a lot of stress but

⏹️ ▶️ it’s i think worth it to serve and see the community

⏹️ ▶️ around swift grow and see people use it and see people learn it and it’s been

⏹️ ▶️ a lot of fun

Swift use by Apple

⏹️ ▶️ so i’m curious um i know when swift first came out it was hard to get a lot of adoption

⏹️ ▶️ inside of apple for various you know tooling reasons among maybe whatever else

⏹️ ▶️ was going on um how is internal adoption going today like are we seeing meaningful

⏹️ ▶️ adoption now or is that most as programmers were using it and not anybody inside the swift

⏹️ ▶️ team itself has specific goals they need to achieve before there can be truly

⏹️ ▶️ across the board adoption at apples a b stability is the number

⏹️ ▶️ one thing that prevents framework developers for example from adopting swift so that’s

⏹️ ▶️ a really important thing and that’s one of the reasons it’s always a really high priority but swift

⏹️ ▶️ has been adopted by application developers and other things the dock is public with

⏹️ ▶️ playground app is public the music app in i o s is publicly known so there there are

⏹️ ▶️ definitely some big big adopters more broadly though the big problem is that

⏹️ ▶️ i think i won’t speak for everybody but many many people

⏹️ ▶️ doing object sea development at apple are chomping at the bit they want to be using swift and so it’s it’s really

⏹️ ▶️ a matter of just getting the technology problem solved and get you know checking out the things that are

⏹️ ▶️ holding people back it’s not about um you know people dragging their feet and not wanting

⏹️ ▶️ to use it makes sense yeah that’s really awesome from the outside it’s so hard to figure

⏹️ ▶️ out you know is apple internally like oh really or or is apple

⏹️ ▶️ internally like you said like really excited and i’m sure that there’s some of both but but that’s really good to hear

⏹️ ▶️ and i think it’s also changed over time when swift first came out of course it was a huge surprise

⏹️ ▶️ for most of the software team and so you know many people

⏹️ ▶️ went went through the usual phases of and rat no objectives why why would i learn this new

⏹️ ▶️ thing objective is great and objectives is great so that that’s that’s an objective statement

⏹️ ▶️ right um but i think things have shifted over time and as swift

⏹️ ▶️ as mature it’s definitely become a lot more appealing one one other technology

⏹️ ▶️ problem that is hilarious but also really important is um the

⏹️ ▶️ apple framework stack has to support thirty two bit mac aps and thirty two bit mac apps

⏹️ ▶️ have this interesting challenge of they have what’s called the classic objective sea run time

⏹️ ▶️ which doesn’t support things like non fragile instance variables and things like that and

⏹️ ▶️ so at some point in time the swift team will need to make the swift runtime work in that mode

⏹️ ▶️ or figure out some other solution to adapt it because until that happens it

⏹️ ▶️ won’t be possible you swift and acat for example that’s fascinating

⏹️ ▶️ so kind of taking a more broad view

Transitional feelings

⏹️ ▶️ do you could you name either your most proud accomplishment during your time at apple that

⏹️ ▶️ you can discuss publicly anyway or if not your most proud just one the first one that jumps to mind

⏹️ ▶️ well um i don’t know i’ve been really fortune to work on

⏹️ ▶️ so many really important projects and um i mean i think that uh

⏹️ ▶️ between lvm and swift for example it’s really a hard call um swift

⏹️ ▶️ i think ah impacts more people in terms of the number

⏹️ ▶️ of people that actually know they’re using it and want to learn it and things like that but

⏹️ ▶️ i think that l b m has been picked up and used so far across industry and it’s kind of standardizing

⏹️ ▶️ the world’s compilers i think that that’s probably more profound at this point

⏹️ ▶️ so it’s really it’s a it’s a hard call i mean there are there are a

⏹️ ▶️ ton of really really great opportunities that i’ve had and it’s

⏹️ ▶️ been a lot of fun over many years now also outside the open source pieces working

⏹️ ▶️ with the exco team and working with the other teams and developer tools has been really phenomenal i mean there’s so

⏹️ ▶️ many great people at apple and in developer tools it’s it’s just been a joy so

⏹️ ▶️ what do you expect to miss most about being an apple and i’m going to take i’m going to let you expound

⏹️ ▶️ on this but i’m going to take it off the table and so you have to pick like your second choice you’re going to say like you miss the people because

⏹️ ▶️ of course you do right that that is actually what i would say right but but you know so

⏹️ ▶️ go ahead and tell us about all the great people you work with apple but besides that what do you expect to miss most about

⏹️ ▶️ apple the company work well so the great thing about apple and the thing that i don’t think that many

⏹️ ▶️ people really get about apple is that it is really

⏹️ ▶️ one of the few best places in the world where you can work hard

⏹️ ▶️ but also work on products that ship and that ship to millions

⏹️ ▶️ of people so that your hard work ends up mattering right there there are a lot of places

⏹️ ▶️ you can work hard there’s a lot of places that you can work on interesting

⏹️ ▶️ things but there’s also a lot of places that end up not shipping a lot or

⏹️ ▶️ or if they ship it very few people actually use it and so apple’s really really

⏹️ ▶️ magical in that it combines being you know being able to work hard and do great

⏹️ ▶️ things with it actually mattering and to me that that’s the thing that that is just so

⏹️ ▶️ so phenomenal about apple so so moving on to your new role at

⏹️ ▶️ tesla do you think that swift will still be a major part of

⏹️ ▶️ your work life in some way like you know or will it basically be like something you do in the evenings

⏹️ ▶️ and weekends because we all know that that silicon valley tech startups don’t usually work people too hard so you’re going

⏹️ ▶️ to have tons of free time yes this jump i’m making is definitely to cush

⏹️ ▶️ so

⏹️ ▶️ so i don’t know we’ll have to see um i haven’t

⏹️ ▶️ started yet and i think it’s going to be a very challenging job and one of the reasons i’m excited about it is because i really

⏹️ ▶️ want to throw myself into another hard technology problem and so i’m really excited about

⏹️ ▶️ that i do expect to be involved with the design of swift and helping

⏹️ ▶️ helping with the curtin and helping swift evolution process and helping in a lot of that kind of respect

⏹️ ▶️ but one of the things to keep in mind is that swift is actually a really tiny slice

⏹️ ▶️ of my job at apple and so um you know i had

⏹️ ▶️ a very full schedule dealing with lots of other stuff and it was already kind of nights

⏹️ ▶️ and weekends project that i was coating on it and i’m contributing at the level that i was

⏹️ ▶️ so i’m hoping that there won’t be a big change but honestly i’ll have to see um obviously

⏹️ ▶️ i care a lot about swift and i really want to get to its goal of world

⏹️ ▶️ domination so we’re sponsored tonight by ero

⏹️ ▶️ to ero dot com that’s e e r o dot com and use code at p when you order for free

⏹️ ▶️ excited shipping wifi is broken you probably have one wifi router

⏹️ ▶️ with if you’re lucky a bunch of antennas on it that look hideous and you’re trying to cover your

⏹️ ▶️ whole house with wi fi but it just doesn’t reach every room it just doesn’t reach everywhere because wi fi is

⏹️ ▶️ hard when years covering it from one point ero solves this problem by having a

⏹️ ▶️ router system where they will they have this little era unit it’s nice it’s attractive it’s tastefully designed there’s not

⏹️ ▶️ a bunch of antenna sticking out of it and you can buy one of them or you can buy ten of them or any number

⏹️ ▶️ in between and that you can put them around your house and each one covers the area

⏹️ ▶️ in wi fi and they all talk to each other wirelessly so you don’t have to run wisely over your house

⏹️ ▶️ you can have your entire house blanketed in wi fi with ero and they talk to each other over this

⏹️ ▶️ mesh network so it’s even faster than previous if you ever used like an extender or anything else extenders are very

⏹️ ▶️ slow it’s even faster than that by a lot an ero is true enterprise grade quality

⏹️ ▶️ and performance they have everything you need from encryption features to things like parental controls and

⏹️ ▶️ they’re actually updating it over time they’ve done over twelve updates since long with more to come to add features

⏹️ ▶️ they have an app for very easy set up and they have incredible customer support if you need

⏹️ ▶️ it they recommend one euro per thousand square feet so the typical home will have two or three of them they got a three

⏹️ ▶️ pack as a as a pretty reasonable starting point for almost everybody there’s a thirty day money back guarantee if you

⏹️ ▶️ don’t like it or if you just buy too many you want to return a couple of them if you end up not needing as many as you bought

⏹️ ▶️ check it out the reviews are stellar they back this up go to ero dot com

⏹️ ▶️ that’s e e r o dot com and use code at p when you order for free date

⏹️ ▶️ shipping

Open-sourcing

⏹️ ▶️ thank you very much to ero for sponsoring our show

⏹️ ▶️ is open source

⏹️ ▶️ yeah right how do you feel like it’s been going so far and and i’m assuming

⏹️ ▶️ similar to john you know i’m going to take away the obvious answer if it’s going well but it may be

⏹️ ▶️ it’s kind of a cute conversation what what’s been really surprising about going

⏹️ ▶️ open source and and you can get as specific or as broad as you’d like to be but i got to imagine

⏹️ ▶️ that that you guys had a bunch of expectations about what going open source would be like and i would

⏹️ ▶️ imagine some of them were accurate and some of them weren’t so how do you feel like the swift open source project has been going

⏹️ ▶️ yes so i think that to to summarize it’s not just going well it’s going

⏹️ ▶️ far better than we ever anticipated and that caused problems

⏹️ ▶️ so for context i and many of the other people in the

⏹️ ▶️ team had quite a bit of open source experience so alva and clang for example were open source

⏹️ ▶️ um they they were they are vibrant and amazing communities

⏹️ ▶️ with hundreds of contributors and dozens of companies all

⏹️ ▶️ collaborating in public and doing really amazing stuff even some of the you know most staunch

⏹️ ▶️ competitors you know m m d and intel and amd and an video

⏹️ ▶️ or you know these kinds of companies that really um you know don’t get along on the business side

⏹️ ▶️ of things but the engineers were great at working engineered engineer and solving

⏹️ ▶️ problems and staying focused on making things better so with swift we we assumed

⏹️ ▶️ that it would be very similar to that but what we found is that there

⏹️ ▶️ was a major difference between launching swift and launching something like clang for example which is

⏹️ ▶️ that when swift launches open source which was december third just over a year ago

⏹️ ▶️ um it already had i don’t know a million users

⏹️ ▶️ and where a clang started and everybody yawned and

⏹️ ▶️ i didn’t really care and grew slowly a swift open source started and was

⏹️ ▶️ amazingly fast moving changing tons of people hundreds

⏹️ ▶️ of patches on the first day it was totally crazy and we didn’t really know what to do and so

⏹️ ▶️ um i mean it i am like super impressed with the the swift open source community and

⏹️ ▶️ all the people involved in the energy and just i mean it’s just it’s hard it’s hard to believe

⏹️ ▶️ how how great everything is but it really did great problems because we had to figure out

⏹️ ▶️ things like how we’re going to stay up on in terms of the patch volume okay we’re getting hundreds and hundreds of

⏹️ ▶️ emails a day to the swift evolution mailing list what are we going to do about that how how do we balance

⏹️ ▶️ a apple’s goals for pushing swift forward with the goals of the community

⏹️ ▶️ which are somewhat more chaotic and less directed and i think that

⏹️ ▶️ over the last year we’ve learned a lot and you can see that reflected in terms of how the projects

⏹️ ▶️ being managed and how how things are being done but it’s always been super important to

⏹️ ▶️ be not just open source but um i guess if

⏹️ ▶️ you look at an open source project there’s there’s three kinds of easy levels to look at it

⏹️ ▶️ the first basic requirement that you have to satisfy to the open source is to make your code available

⏹️ ▶️ right and so you can produce tarballs periodically and that’s technically open source

⏹️ ▶️ you can allow contributions and if you do that through pull requests

⏹️ ▶️ or patches or whatever then people can engage with it and make the code

⏹️ ▶️ better there’s open community so not only can do you accept a patch but

⏹️ ▶️ you actually discuss things and um talk about things in public and then there’s open

⏹️ ▶️ design and with swift we went all the way and i think it was totally the right thing to do because we

⏹️ ▶️ really wanted to benefit from all the smart people in the world and it was and still

⏹️ ▶️ is amazing but it’s also very challenging yeah i can imagine so building

⏹️ ▶️ upon the open sourcing of swift it was very surprising to me and

⏹️ ▶️ i think a lot of the community that apple chose to upload the entire commit history it

⏹️ ▶️ wasn’t just a here’s day one initial commit in its you know eleven gazillion files and eighty gazillion

⏹️ ▶️ lines of code was that planned from the start that you guys would upload the entire history

⏹️ ▶️ i wouldn’t say it was planned from the start that we’d upload the entire history but it was

⏹️ ▶️ kind of assumed from the start that it would be open source at some point um interesting and

⏹️ ▶️ if you look at apple’s history i think that’s that’s in the tool space

⏹️ ▶️ i think that’s fairly straightforward lvm wasn’t started

⏹️ ▶️ at apple but almost almost everything apple

⏹️ ▶️ does ends up going public in the elvin space klang was started at apple

⏹️ ▶️ and klang was contributed by apple to the elvin project and

⏹️ ▶️ that included its full revision history other projects like l d b and lips plus

⏹️ ▶️ plus and compiler and all these other smaller projects were started

⏹️ ▶️ at apple and contributed to the open source project so swift it was kind of assumed that that would happen

⏹️ ▶️ at some point the real question was when when is the right time for that to happen

⏹️ ▶️ and if you remember the days of swift one dado um swift one datto

⏹️ ▶️ to two dado in particular was a super chaotic super learning as we went

⏹️ ▶️ and trying to keep up with the community and trying to keep up with the pace and the challenges the people were facing

⏹️ ▶️ and trying to get key pieces like the air handling model and protocol extensions and all that kind of stuff that

⏹️ ▶️ had always been planned but didn’t make it into swift one oto and so

⏹️ ▶️ really focusing on that was the priority and so we decided that open sourcing swift

⏹️ ▶️ at one auto for example would be really actually bad for the swift community because there

⏹️ ▶️ are major pieces of language that weren’t there we would have to spend a lot of time

⏹️ ▶️ community building and try and explain to people the difference between what was not there but

⏹️ ▶️ should be there and what is you know there and known broken and we had to do

⏹️ ▶️ a lot of that when swift was eventually open source ten and last year right after

⏹️ ▶️ swift todate but it was a much better place than the team could actually handle the load of doing

⏹️ ▶️ the community and we didn’t expect the kind of response we got but we knew that building a

⏹️ ▶️ vibrant open source community is a lot of work and it’s not something to be under underestimated and we want

⏹️ ▶️ to make sure that swift two was out the door and it wasn’t kind of a resource contention

⏹️ ▶️ between do we finish swift two or do we start open source and that

⏹️ ▶️ and that’s why it was announced to be open source by the end of the year because that meant that we could

⏹️ ▶️ start working on the open source infrastructure project bring up all the other stuff that it takes to make something open

⏹️ ▶️ source after swift two is complete so my recollection of the

⏹️ ▶️ swift three in the planning stages was that abi compatibility was

⏹️ ▶️ somewhere in the list of i don’t know if you want to call them goals but somewhere

⏹️ ▶️ in the list of items that were in contention for a swift three and at some point along the development

⏹️ ▶️ process of swift three abi comparability got postponed and given

⏹️ ▶️ what you just said about the importance of a b i compatibility for the framework people inside apple or whatever um

⏹️ ▶️ what can you say about that did you learn lessons from

⏹️ ▶️ a the abi compatibility being planned for swift three or do you think like it was

⏹️ ▶️ never really a hard and fast goal and you totally made the right call to delay it or you disappointed that it didn’t make

⏹️ ▶️ it um well i think many of those things i mean were disappointed that it got delayed but it

⏹️ ▶️ was totally the right thing um i think that there’s a couple of things to learn from that one of

⏹️ ▶️ which is software schedule planning is hard

⏹️ ▶️ breaking yeah so that’s definitely still a thing um there’s

⏹️ ▶️ also that we didn’t anticipate the so the original plan they’re referring

⏹️ ▶️ to was announced before swift was open source sorry was announced the same time swift is open

⏹️ ▶️ source and so we had no idea that the community would descend on swift and suddenly

⏹️ ▶️ have all these new demands and consume so much time and energy

⏹️ ▶️ for that kind of took away from programming to do the community building piece so that was part

⏹️ ▶️ of it another part of it is that um abi stability is super important but

⏹️ ▶️ it’s not as important as people think it is for application developers it’s really important

⏹️ ▶️ to apple but um what we realized in the swifter time frame is that the thing

⏹️ ▶️ app developers would benefit from the most was actually source stability

⏹️ ▶️ so who who actually wants their application be broken when they get a new version of xcode

⏹️ ▶️ well really nobody right and so and so kind of half way

⏹️ ▶️ through the release we pivoted and source source stability became the goal and so i’m

⏹️ ▶️ really excited that when swift three dot one or swift four comes out that it’s still

⏹️ ▶️ going to be able to build swift three code and even if there are minor changes that need to be made

⏹️ ▶️ for one reason or another that you can upgrade and you have great compatibility

⏹️ ▶️ with your old code and you don’t have to start the migrator before you can do anything so this can be

⏹️ ▶️ a great improvement for people’s lives

Server-side Swift

⏹️ ▶️ all right so moving on a little bit to kind of this branch topic here of

⏹️ ▶️ server side swift swift on linux things like this um is

⏹️ ▶️ is swift on the server something that you know i know it’s possible

⏹️ ▶️ and there’s like some seemingly some early efforts now to get that going do you see this

⏹️ ▶️ as like a major goal for swift as the language and you know not not in any kind of

⏹️ ▶️ official capacity but just like you as a person who who likes and uses swift and has has a

⏹️ ▶️ you know a strong role in the community like is server side swift

⏹️ ▶️ a thing that you want to be like a major thing to compete with with you know things

⏹️ ▶️ like pipe on rails and stuff on the server or is it intended more be to be kind of

⏹️ ▶️ like a specialized thing that is probably not going to be in widespread use by like web and back end programmers

⏹️ ▶️ so i think that everybody involves with the project

⏹️ ▶️ wants it to be the way to do server development and i think

⏹️ ▶️ that to understand that you have to understand we’re just kind of entering phase

⏹️ ▶️ two of swift’s world domination plan so

⏹️ ▶️ this will probably sound insane but maybe in a few years it will sound lessons insane

⏹️ ▶️ but the way to look at the way i look at it and the way that many other

⏹️ ▶️ people would have to look at it is that we want swift to be the next big thing right

⏹️ ▶️ we want it to be more popular than java was or is we want to be more popular than python we want

⏹️ ▶️ to be maybe even more popular than sea someday right that’s that would be a stretch but but

⏹️ ▶️ that would be great and so if if that’s the problem to solve how do you solve that problem well

⏹️ ▶️ open source is a huge piece of that right without open source it’s not going to be available on other people’s platforms

⏹️ ▶️ it’s not going to be used in education and teaching that that’s just not going to happen and so opens

⏹️ ▶️ source is a major piece of that um if you go back further before that

⏹️ ▶️ swift world domination doesn’t happen unless swift gains relevance

⏹️ ▶️ right and i think swift has nailed the relevance side of things with the ios

⏹️ ▶️ and apple platform development side of the story where um you

⏹️ ▶️ know maybe not marco but most other people are switching to swift very quickly

⏹️ ▶️ and seemed very happy using it actually i started using it today okay good call i switched today

⏹️ ▶️ in honor of this interview i wrote my first swift today an entire

⏹️ ▶️ extension and overcast through porno is written in swift wow see fantastic let you

⏹️ ▶️ go i’m proud of you it is a good day yeah and more more will be coming although

⏹️ ▶️ there’s a lot of justice there so probably a long way away from it being all swift

⏹️ ▶️ well that’s that’s okay swift loves objectives exactly so

⏹️ ▶️ the way i look at it is that the first step of world domination is getting to relevance

⏹️ ▶️ and for language get relevance it needs a killer a killer app it needs a reason why

⏹️ ▶️ people would want to use it and for swift that’s clearly i west and mac and other apple platform

⏹️ ▶️ development second needs the open source third it needs to

⏹️ ▶️ go beyond right and the next the next step the

⏹️ ▶️ frontier of where it makes sense to expand out to or your you know real time strategy game player

⏹️ ▶️ the natural expansion is a place where the language

⏹️ ▶️ is where the language actually only needs

⏹️ ▶️ a few things added to it to be good and so i think server development is really that next step because

⏹️ ▶️ server development is very similar to apt development in terms of the kinds of code that you need to write is very similar

⏹️ ▶️ in terms of many of the frameworks the major missing piece is that

⏹️ ▶️ it needs to run on linux and other pertinent server development platforms

⏹️ ▶️ and there’s then the whole library ecosystem that needs to be built out and so

⏹️ ▶️ i think that what we’re in right now is we’re in a really exciting phase where those platforms

⏹️ ▶️ are being built those frameworks and different pieces of infrastructure coming together

⏹️ ▶️ and that’s that’s really the idea behind the swift server working group that’s an official part of

⏹️ ▶️ swift dot org is getting all the people working in the space to talk to each other and i’m very

⏹️ ▶️ excited about that um going beyond that though you know it with the goal

⏹️ ▶️ of being more relevant than java for example if we’re going to pick on java

⏹️ ▶️ the dream of swift is to scale all the way from scripting language

⏹️ ▶️ all the way down to low level systems programming like you could write a kernel in it or you

⏹️ ▶️ write some firmware in it and i think the the scripting side of it is

⏹️ ▶️ maybe more straightforward when when the the swift community and the court

⏹️ ▶️ team have time to deal with it because they’re you’re talking about integrating regular

⏹️ ▶️ expressions integrating multiline string literals and integrating other other features like that that

⏹️ ▶️ people love from scripting languages and those are big projects but

⏹️ ▶️ those are kind of well known i guess and they will fit and drop right into the existing

⏹️ ▶️ existing a system that swift provides

⏹️ ▶️ systems programming is i think the big the big next frontier and i think that’s where

⏹️ ▶️ swift can really distinguish itself from java or other other competitive

⏹️ ▶️ languages because among other widely used languages out there there’s

⏹️ ▶️ really nothing that can use c or c plus plus there’s a rust for example

⏹️ ▶️ is an interesting language but it hasn’t gotten a lot of adoption yet and i think that

⏹️ ▶️ swift is more interesting than rust in some of the higher level application demands

⏹️ ▶️ but we’ll see rust is a great language as well and so i’m really interested

⏹️ ▶️ to see the swift for systems programming work get

⏹️ ▶️ going and i think that’ll be a couple of years out before it really comes together but once it does

⏹️ ▶️ um i think that swift can be really be the next big thing and i’m excited about that

⏹️ ▶️ so so just stepping back a second to the server role of it you know possibly taking

⏹️ ▶️ over there because like you know i would love like you know here i am using php and objective c these

⏹️ ▶️ these two languages that are fairly old and i mean php is way more hated than objective

⏹️ ▶️ c but you know this these are the two languages i use for various historical

⏹️ ▶️ and practical reasons um on the server a lot of what what makes

⏹️ ▶️ a language succeed or fail on servers and in web development is

⏹️ ▶️ not necessarily how good of a language it is but how how healthy

⏹️ ▶️ and universal and develop the framework around it are for for things like web development

⏹️ ▶️ how practical and easy it is to deploy and run on servers so

⏹️ ▶️ you know swift being being its own good language that

⏹️ ▶️ alone i don’t think is enough to get it to get traction on the server do like do you think

⏹️ ▶️ is it necessary for the swift team like the the

⏹️ ▶️ the core group whose running swift whether that’s apple or the community of contributors

⏹️ ▶️ with apple or whatever else is it important for them to develop and and

⏹️ ▶️ kind of make official an official set of server and web frameworks

⏹️ ▶️ and libraries and tools or do you think it’s sufficient to kind of take

⏹️ ▶️ the risk to let the community do that but at the risk of fragmentation and maybe nothing ever taking off

⏹️ ▶️ also that’s an interesting question and keep in mind that i don’t have a lot of

⏹️ ▶️ practical experience building server apps so this is you know not missing much my my

⏹️ ▶️ my my opinion based on talking to other smart people so

⏹️ ▶️ the approach the swift project taking as its looking to standardize what’s colloquially

⏹️ ▶️ but not correctly known as a server foundation kind of technologies so

⏹️ ▶️ it will not be named server foundation but that that kind of an idea and so take the

⏹️ ▶️ encryption the network transport the h t p kinds of things that that everybody

⏹️ ▶️ needs for server technologies and standardize that as part of the swift project but at least

⏹️ ▶️ in the short term not look to standardize a specific web framework because there are half a

⏹️ ▶️ dozen different completely different approaches that are interesting in different different kind of domains

⏹️ ▶️ and i don’t think there’s a clear winner yet it’s possible that after the

⏹️ ▶️ first few rounds shake out then there will be an equivalent you know ruby on rails kind

⏹️ ▶️ of dominant pattern and framework that emerges and if

⏹️ ▶️ so then maybe that would make sense but i don’t think i don’t think swift needs for there to be a winner

⏹️ ▶️ at the high level um as far as what can the swift core

⏹️ ▶️ language and language and compiler folks do about this i think there’s really

⏹️ ▶️ two things one of which is the swift package manager i think the package manager is really key

⏹️ ▶️ to scaling out the ecosystem and getting people to work

⏹️ ▶️ together with the common ecosystem it’s also the best and i think only way

⏹️ ▶️ to build swift code on linux and and other platforms i don’t mean to single out

⏹️ ▶️ linux is just the biggest server development one um so i think

⏹️ ▶️ that’s a big piece i think the other piece that they will be really amazing is when the concurrency model comes

⏹️ ▶️ up because i think that’s one of the reasons that makes um go particularly compelling for server

⏹️ ▶️ development as it has really a well developed story there along with all the libraries that go together for

⏹️ ▶️ server and cloud development and so when the pieces the concurrency model start coming

⏹️ ▶️ up which will probably the first pieces will ship in swift five is my guess that will

⏹️ ▶️ make swift and even more compelling kind of answer for that kind of space

⏹️ ▶️ but i don’t think i don’t think we need a server language feature that’s

⏹️ ▶️ what you’re asking

Low to high, easy to hard

⏹️ ▶️ so going to the other extreme from the server side in scripting to going back to

⏹️ ▶️ systems programming one thing i’ve seen related to this and and i think this

⏹️ ▶️ all stems from like this quote from the original apple swift book that swift was

⏹️ ▶️ designed to scale from hello world to an entire operating system like that that it’s that the world domination plan was

⏹️ ▶️ there from the beginning right now absolutely in the first paragraph of the thing um

⏹️ ▶️ when i talk to people now about swift as a systems language

⏹️ ▶️ often what i hear is people relating

⏹️ ▶️ the ways that it is not ready to be a systems language yet which is you know what you just talked about

⏹️ ▶️ but then deciding based on that that because it’s not ready to be a systems language now

⏹️ ▶️ it never will and then they dismiss it like in other words like that may have been the plan

⏹️ ▶️ but clearly for reasons x y and z you still have to use c

⏹️ ▶️ for this therefore swift is just a way to write apps for ios and macos and

⏹️ ▶️ ah how i mean i’m not quite sure what you can do by that but do you think about

⏹️ ▶️ um how how to change perception as the language gets older

⏹️ ▶️ in its old age now it’s up to three point not like the i arse you know that that nobody puts swift

⏹️ ▶️ in a corner like that that people think they know people think they know what swift is and they say oh it’s this language

⏹️ ▶️ does this thing and that your plans for world domination may be thwarted by the idea that people

⏹️ ▶️ are pigeon holing language because it’s been around for a few years and i think they know it i think that you’re on to something

⏹️ ▶️ i think that’s a real problem i don’t think systems programming is the place where that’s a problem yet though because if i

⏹️ ▶️ don’t think it’s it’s reasonable for me as a crazy man going around saying swift

⏹️ ▶️ swift will someday do systems programming really well you should you should remember that i don’t i

⏹️ ▶️ don’t think that that’s a good way to spend time at the moment when it does that then

⏹️ ▶️ the question becomes how do you make that make people aware of that

⏹️ ▶️ and how do you get get people to change their prior misconception but at that point in time you

⏹️ ▶️ can have very practical look you can do this and this is so great and now you get all the advantages

⏹️ ▶️ of see but it’s safe and you can point to specific reasons why it’s better

⏹️ ▶️ so i’m not too worried about it in the space of systems programming but i think there is a practical

⏹️ ▶️ problem today which is swift is open source

⏹️ ▶️ ah the apple development community knows swift very well but pretty much everybody

⏹️ ▶️ else doesn’t right and if you go to a random

⏹️ ▶️ ah say linux developer just continue talking about linux

⏹️ ▶️ they all perceive swift as being an apple thing and only relevant to apple

⏹️ ▶️ platforms and they don’t even learn about it right and so i think that

⏹️ ▶️ there is an interesting challenge there and probably the best way to do that is for

⏹️ ▶️ the existing communities who keep just growing and

⏹️ ▶️ as the swift on server community grows and more and more people are successful

⏹️ ▶️ building and deploying server after and swift i hope that naturally more and more people will become

⏹️ ▶️ aware of that effort will will then find out about swift maybe try

⏹️ ▶️ it out find out that it’s actually really great and if it’s not really great let us know so that

⏹️ ▶️ people can fix whatever the problems are and then just kind of grow out but i’m i’m

⏹️ ▶️ actually perfectly okay with it growing a little bit slower than it has been

⏹️ ▶️ so so john asked about you know this span between basically low level systems programming and high level applications

⏹️ ▶️ programming i’m also curious that it seems like the swift team slash apple

⏹️ ▶️ have have presented swift as not only spanning that wide range which seems

⏹️ ▶️ impossible but also spanning a wide range of skill levels of programmers so you know

⏹️ ▶️ there’s there’s the swift playgrounds app an ipad where you have total novices writing swift as their

⏹️ ▶️ first language all the way up to people writing like you know systems level things and

⏹️ ▶️ complicated apps who are very experienced programmers do you think is it

⏹️ ▶️ even is it possible for language to do all of these things well and if

⏹️ ▶️ so do you think swift has achieved that so i do think it’s possible

⏹️ ▶️ i think it has achieved it for the things that it’s doing so far and i think the challenge

⏹️ ▶️ is that as new capabilities get added that it doesn’t jeopardize that but knowing

⏹️ ▶️ knowing the the folks involved and the source compatibility guarantees and everything else like

⏹️ ▶️ that i’m pretty sure that won’t be a problem going for here’s the way i look at swift um

⏹️ ▶️ you will never you’re unlikely to run to anybody that says that swift is a simple language

⏹️ ▶️ right swift is a complicated language it’s not simple in the sense that

⏹️ ▶️ scheme is simple for example is also not simple in terms of when you talk

⏹️ ▶️ to an object c a developer they they’ll often claim that objective is simple ignoring all the sea

⏹️ ▶️ parts i would never claim that for the record all right so um c itself is a

⏹️ ▶️ is a very complicated weird language it’s just that people don’t typically use the weird parts

⏹️ ▶️ right and so they perceive as being very simple ah the

⏹️ ▶️ ah so the way the way the way i project the on swift is that the secret is

⏹️ ▶️ swift and being easy to learn easy to use as

⏹️ ▶️ a teaching vehicle but also powerful enough to solve the problems that need to be solved

⏹️ ▶️ is that the complexity inherent in the language needs to be progressively disclosed

⏹️ ▶️ so imagine if some day swift had inline assembly support for example only really

⏹️ ▶️ low level systems people are really bit twiddling assembly programmers would use this feature

⏹️ ▶️ everybody else would ignore it and it would not increase the apparent complexity to the language of the language to

⏹️ ▶️ people who didn’t know what it was for a feature like that the most important thing is to make the syntax clear so

⏹️ ▶️ that when you run up into it you discover somebody else’s code you know that you don’t

⏹️ ▶️ know what it does right and so you say oh that’s interesting i don’t know

⏹️ ▶️ what that is and then you can do a search and find out find a stack over force whatever

⏹️ ▶️ it is to say explain what this is to me and then you can say okay i get it and i either care or i don’t

⏹️ ▶️ but at that point in time you can then dive in and learn learn more information

⏹️ ▶️ assembly is never something that a swift playgrounds person working through learn a to code three would

⏹️ ▶️ ever want to know about it and and i think that is really the one of the

⏹️ ▶️ secrets to swift a success in terms of getting people on board and and being really approachable

⏹️ ▶️ for people at all levels is that um just like in python you

⏹️ ▶️ can start with just print hello world you can do the exact same thing and swift and with swift you don’t need

⏹️ ▶️ the slash end on your string it’s really just print hello world and from

⏹️ ▶️ there you can then introduce new concepts you can grow it out over time and this really allows people to

⏹️ ▶️ ah understand either the syntax language or the conceptual

⏹️ ▶️ programming things that they’re learning as they go and um the design of swift

⏹️ ▶️ is really geared around that and so what that means if you project on assistance programming features comparing

⏹️ ▶️ swift to rust for example i think it’s very likely that swift will get

⏹️ ▶️ features for memory ownership control which will allow really really high

⏹️ ▶️ performance and allow solving performance problems with arc for example but unlike

⏹️ ▶️ rust we can’t make that be a core part of the type system that everybody has to use it has

⏹️ ▶️ to be something that sufficiently smart programmers when they’re solving a specific performance

⏹️ ▶️ problem and abusing or an embedded kernel programmer might want

⏹️ ▶️ to use but an application developer can completely ignore and so that’s really the challenges

⏹️ ▶️ it’s a deploying similar type system mechanics and other low level language

⏹️ ▶️ geekery to the problem but do so in a way that is tasteful and allows most

⏹️ ▶️ normal people to just completely ignore it everything you just said kind of reminds me

⏹️ ▶️ of a saying i once heard that your freda would opt for swift if you would like which is make easy things easy and make hard things

⏹️ ▶️ possible we are sponsored to night by audible

⏹️ ▶️ with an unmatched selection of audiobooks original audio shows news comedy and more

⏹️ ▶️ get a free thirty day trial at audible dot com slash at p if you want to

⏹️ ▶️ listen to it audible has it you can listen to audio books from virtually every genre any time anywhere you

⏹️ ▶️ can play audible audiobooks on phones tablets computers even kindles and ipods

⏹️ ▶️ if you still have them audiobooks are great for flights long road trips or even your daily

⏹️ ▶️ commute you might think you don’t have time to read books but you’d be surprised how many audio books you can hear each

⏹️ ▶️ year even only listening to and from work every day because that time really adds up audiobooks

⏹️ ▶️ bring books to life many of them are read by authors themselves which adds an extra dimension to the text

⏹️ ▶️ and with audible you can take risks and try new authors without regret because audible

⏹️ ▶️ offers their great listen guarantee if you start an audio book and don’t like it you can exchange

⏹️ ▶️ it for another one for free so check it out for yourself you can see and listen when

⏹️ ▶️ you begin your free thirty day trial you get your first audiobook for free and there’s no stress and

⏹️ ▶️ no obligation because you can cancel your audible membership at any time so with audiobooks and spoken

⏹️ ▶️ word audio products you will find what you’re looking for get a free thirty day trial by signing

⏹️ ▶️ up at audible dot com slash atp that’s audible dot com slash at

⏹️ ▶️ p

Influences

⏹️ ▶️ thanks to audible for sponsoring our show

⏹️ ▶️ so chris you brought up just a second ago how simple python’s

⏹️ ▶️ hello world is and one of the things i’ve wondered about swift is

⏹️ ▶️ it seems to some degree like it’s kind of what do you call it the roca test of languages

⏹️ ▶️ in that i came to swift a sort of kind of objectives

⏹️ ▶️ but but my day job was as a sharp guy and i see to my eyes anyway and i hope

⏹️ ▶️ you don’t find this insulting but i see a lot of sharp i see a lot of sharp and swift and i’ve

⏹️ ▶️ heard javascript people again i hope that’s not insulting say oh i see some javascript in here and i presume that john

⏹️ ▶️ could say that that he sees pearl in it i presume marco could say that he sees php in it but hopefully that’s

⏹️ ▶️ not insulted i see in it i don’t see any php you get what i’m driving at

⏹️ ▶️ though and so so i guess what i’m asking chris is obviously there was a huge object to see

⏹️ ▶️ influence and swift but was there any one or maybe just a couple of other languages that you

⏹️ ▶️ feel really really inspired swift or or do you really think it’s it’s the melting pot language

⏹️ ▶️ that that one would always hope to create my final is a melting pot because we weren’t

⏹️ ▶️ so the gold swift isn’t to ape some other language is to

⏹️ ▶️ just be great right right and so you can take a think that swift

⏹️ ▶️ looks or i and the other people in the court team and the other people working working on swift

⏹️ ▶️ have looked at many many other languages if your haskell nerd there’s tons of haskell

⏹️ ▶️ concepts built in protocols really are just like a very similar haskel

⏹️ ▶️ construct for example and so it’s really about taking

⏹️ ▶️ the best ideas from where we can get and assembling them together and one of the major goals of swift

⏹️ ▶️ is for to be familiar feeling right because of its familiar feeling that makes

⏹️ ▶️ it easier for people to pick up and they’re not fighting unnecessary

⏹️ ▶️ barriers to they just get in the way of adoption and so it being familiar is

⏹️ ▶️ actually success in that way and it’s not it’s not a result of

⏹️ ▶️ a swift trying to be go or see sharp or whatever is about taking the

⏹️ ▶️ best ideas from them and assembling them together and i think that you could probably pick a language

⏹️ ▶️ and there’s some some good idea that came from them including you know d or

⏹️ ▶️ dart or go or whatever i mean swift does really draw

⏹️ ▶️ from many many different sources and it’s really hard to um to really

⏹️ ▶️ tease them all out

Why adopt now?

⏹️ ▶️ so the question that casey wrote for me to ask you right now is how

⏹️ ▶️ do you know that was me that’s definitely you why should i give a shit about swift

⏹️ ▶️ right now and i think i’m going to modify this a little bit that was written

⏹️ ▶️ that was written for you my friend yes that is how you right i figure that’s not quite john style

⏹️ ▶️ oh no but but i i i you know as as somebody who is just

⏹️ ▶️ dipping a toe and swift you know as of twelve hours ago um you know and has waited

⏹️ ▶️ this long you know object to see faithful slash hold out slash lazy people who don’t like learning

⏹️ ▶️ new things very quickly what’s kind of like the sales pitch for adopting swift now

⏹️ ▶️ um i guess two different answers one of which is you don’t have to adopt swift

⏹️ ▶️ i don’t think objective s is going to go away any time soon apple still sports c

⏹️ ▶️ and c plus plus and it doesn’t have any specific ben there’s no obvious benefit

⏹️ ▶️ of dropping objectives c as well as obviously they have a ton of object to sea code themselves so

⏹️ ▶️ i don’t think that there’s any reason you have to adopt swift swift

⏹️ ▶️ just tries to be a better answer so that you will want to adopt it and in terms

⏹️ ▶️ of why a swift in its name kind of it connotes

⏹️ ▶️ a whole bunch of different things including performance but really to me the most important aspect of

⏹️ ▶️ it is programmer productivity the idea that swift is really optimizing for is not

⏹️ ▶️ letting you pound out the code as fast as possible it really is designed and optimized

⏹️ ▶️ for as a programmer you can spend the least amount of time to get to a working program

⏹️ ▶️ as fast as possible and so getting to a working program includes the time it

⏹️ ▶️ takes to debug something includes the time it takes to iterate and develop and fight the type system

⏹️ ▶️ and all the other things that you have to do but that time you spend

⏹️ ▶️ having to fight the type system or figure out optionals or things like that pays itself back

⏹️ ▶️ because your program works more often and so you’re actually not spending time chasing down dangling

⏹️ ▶️ pointer bugs or um you know in the case of objectives

⏹️ ▶️ you get an unrecognized selector you know whatever whatever those kinds of bugs are

⏹️ ▶️ an swift tries to help you by the language guiding you and helping design things

⏹️ ▶️ swift also has a lot of things that just make common things easier so you can switch on a string

⏹️ ▶️ for example and then match the different cases you can use enums which are a super

⏹️ ▶️ enums or just from the language geekery world just algebraic data

⏹️ ▶️ types they are in tons of different functional languages um they’re not novel by any means but they’re

⏹️ ▶️ so useful and they solve so many problems just out of the box and just having

⏹️ ▶️ your fingertips is great so there’s there’s a lot of things about swift and it probably depends on who you are

⏹️ ▶️ what your experiences are one of the problems i’ve seen with people moving from objective sea to swift

⏹️ ▶️ initially is that they tend to write swift code just like they wrote objective s and while that’s a

⏹️ ▶️ really good way to maybe migraine application over or to get familiar swift

⏹️ ▶️ it really means that you’re missing a lot of the value in swift and and i think that that’s

⏹️ ▶️ ok it’s just it means that you know an objective c program we’re going to swift first

⏹️ ▶️ starts out by saying i don’t see what the big deal is and only after they spend some time in it till they start

⏹️ ▶️ to realize they they are more productive they do feel better they reach for things that they

⏹️ ▶️ otherwise wouldn’t have and i think it’s really interesting to talk to people that

⏹️ ▶️ have done for example a year of swift programming but then have to go back to objective sea and to me that’s

⏹️ ▶️ i’ve been there that’s the really interesting thing so so it was your experience it felt

⏹️ ▶️ absolutely archaic and granted i’m an i like to think of myself as a nice guy and so i’d probably say

⏹️ ▶️ something like that even if it wasn’t true but the reality situation is it felt just so

⏹️ ▶️ oh old it just felt old and i don’t know i wish i could quantify

⏹️ ▶️ that better but it just felt like i was back in time in a way that

⏹️ ▶️ didn’t feel good and in some things like in some ways it was kind of nice so i

⏹️ ▶️ do like optionals i understand why they are a thing i am all

⏹️ ▶️ in on it but at the same time there are times when i have to do a guard letter whatever the case may be that that i

⏹️ ▶️ really would just like to move on with my life and so not having to worry being

⏹️ ▶️ being able to be a little more cavalier was kind of nice but the reality the situation

⏹️ ▶️ is as you as you’ve said earlier is that that’s a potential hazard down the road and and that’s

⏹️ ▶️ why i like the way that you and the team have set up the type system and swift but gosh

⏹️ ▶️ going back to objective c is so frustrating for me because it just feels like i’m going back

⏹️ ▶️ in time like i’m going backwards and i think that the challenge that swift faces

⏹️ ▶️ is because its focus is on building you know programs at work and that

⏹️ ▶️ can be maintained and all the other things that we care about for large scale software it’s

⏹️ ▶️ maybe not the best solution for i want to pound out a

⏹️ ▶️ quick script use it once and then throw it away right because in that case you don’t care

⏹️ ▶️ about maintenance you can fit all the code in your head you don’t care about um good

⏹️ ▶️ documentation on of the other things that swift encourages and um that’s that’s a case where having a dynamic

⏹️ ▶️ type system can be really really liberating and so

⏹️ ▶️ you know maybe that’ll be a challenge for some people but i think that as swift gains ecosystem against

⏹️ ▶️ libraries its other advantages will be so great that hopefully it

⏹️ ▶️ will be a good solution for those kinds of tools as well those kinds of scripts as well

Style and idioms

⏹️ ▶️ so a minute ago you mentioned how objective sea programmers people like me who are new to swift um

⏹️ ▶️ tend to write swift like objective s and and that’s that’s a concern i’ve had and

⏹️ ▶️ it’s one of the reasons that i have procrastinated adopting swift up till now

⏹️ ▶️ because i have i have a pretty good grasp on object c s now and

⏹️ ▶️ i i write objective sea code that i know is basically

⏹️ ▶️ idiomatic and and soundly designed like i write code in the

⏹️ ▶️ style of what i think apple’s code would look like based on the little bit of you know headers and stuff that we see

⏹️ ▶️ i feel like i write good objective sea code that is kind of correct and an idiomatic lly sound

⏹️ ▶️ with swift you know i assumed that the the idioms would not yet be developed

⏹️ ▶️ for a while and and established for a while and so i didn’t want to write a bunch of bad

⏹️ ▶️ swift code um or or like incorrect or or weird

⏹️ ▶️ swift code you know investing heavily in it so early on do you think that it’s at a

⏹️ ▶️ point now where the idioms are starting to get worked out enough that’s less of a

⏹️ ▶️ concern now yeah i do so i think it’s definitely fair to say that in

⏹️ ▶️ the swift one the swift two timeframes swift as the language was changing really rapidly and

⏹️ ▶️ i could see why you’d feel like you’re on uneven footing and not really sure what the language

⏹️ ▶️ is much less what the idioms are swift three really is quite well baked

⏹️ ▶️ out and so i expect that going forward that the new things are going to be additive they’re not going to be

⏹️ ▶️ um changing the existing patterns and so i think the swift community in general has gone through the same

⏹️ ▶️ same kind of thing that you’re feeling there where it’s not really clear the one right way

⏹️ ▶️ to solve the problem and maybe there are different good ways to do it with different trade offs

⏹️ ▶️ that weren’t clear to people but i think that’s i think people are starting to understand that now there are

⏹️ ▶️ a few style books that are being written by people that i’ve heard about and so when those come out those

⏹️ ▶️ will hopefully be good and those will be a good resource but

⏹️ ▶️ another thing to keep in mind is that swift is opinionated i guess

⏹️ ▶️ and it is the way to say it so it really does encourage you to do the right thing here where it can

⏹️ ▶️ and so for example if you use var for everything um the the swift

⏹️ ▶️ compiler will say hey you marked this as a var but it could be a let and that’s

⏹️ ▶️ just its subtle way of and and let me fix it for you right and that’s just its subtle

⏹️ ▶️ way of encouraging you to use immutable values which is a very small thing

⏹️ ▶️ but it’s just kind of pushing you in the way that it thinks leads to better

⏹️ ▶️ code and immutability for local variable doesn’t matter that much except that it communicates something

⏹️ ▶️ more to the person you have to read and maintain your code and um and so i think that swift

⏹️ ▶️ really does kind of encourage you down the right lines in some ways but on the other hand

⏹️ ▶️ in other places where you’re saying hey should something be a class or should it be struck the trade offs are more new one

⏹️ ▶️ and it’s it’s a harder thing and the swift compiler can’t just know what what prom it is that you want to solve and so

⏹️ ▶️ can’t help you with the it you imagine swift style guides before um

⏹️ ▶️ as as a creator of a language um how

⏹️ ▶️ how much influence do you do you feel like you want to have over

⏹️ ▶️ things like style things that really are you know it’s not it’s not features it’s not

⏹️ ▶️ technical it’s just like you know what we all know the different style things like oh you know

⏹️ ▶️ you should only have one exit at the bottom or you should exit early or i mean like there are things you

⏹️ ▶️ can do even things like spacing and brace staff are crying out loud or you know or

⏹️ ▶️ just the sort of idioms of like this little three line sequence is how you do this transformation on this data structure

⏹️ ▶️ um you mentioned you know language features can influence that obviously as language designer in

⏹️ ▶️ participating in that process you can effectively guide the community’s

⏹️ ▶️ style wise in one direction or another but eventually you come to the stuff that’s just plain

⏹️ ▶️ opinion and style and several other languages have had fairly

⏹️ ▶️ concrete styles set forth early on by the creators we want to go like k and

⏹️ ▶️ r c a style type things how much do you care about being able to

⏹️ ▶️ influence the i guess the personal preference or the aesthetic a

⏹️ ▶️ portions of style that are outside the things that you can influence as part of language design

⏹️ ▶️ um so as with any programmer that has a pulse

⏹️ ▶️ i have my preferred style and so clearly that’s the right way um

⏹️ ▶️ naturally naturally um well so i guess more seriously the language itself

⏹️ ▶️ does influence some of the things you mentioned so for example it’s my personal opinion

⏹️ ▶️ that the style where you have a single entry and a single exit from every function i think that leads

⏹️ ▶️ to really difficult to maintain and read code and that’s one of the things that led to the guard

⏹️ ▶️ statement existing the guard really does encourage you to use early exits so you handle the exceptional cases and

⏹️ ▶️ then you don’t have to worry about them so that’s that’s an example of where the language design is

⏹️ ▶️ kind of encouraging you to um you know have multiple returns from a function

⏹️ ▶️ other more subjective things like the number of spaces i personally am a fan of two space

⏹️ ▶️ indents i know some people are staunchly for other people are staunchly eight some people think eighty columns

⏹️ ▶️ is right answer right i mean all these things are there are actually really good arguments on all

⏹️ ▶️ sides some people argue that you should use three space indent because then you certainly can’t

⏹️ ▶️ have tabs in your file well so this is where this

⏹️ ▶️ it comes down to you have to pick your battles and people will disagree

⏹️ ▶️ for a long time and you can make arguments on both sides but the

⏹️ ▶️ in where we’ve come down is that it’s just more practical to let people write code they like

⏹️ ▶️ to look at and that comes at a cost of if you switch between teams or you pick up somebody

⏹️ ▶️ else’s package then maybe it’s intended the wrong way but i don’t think that really actually

⏹️ ▶️ actively hurts the comprehensive comprehensibility of the code that’s

⏹️ ▶️ merely annoying and having something like go format which

⏹️ ▶️ rigorously enforces the one true way i think would have been nice it just wasn’t a priority early

⏹️ ▶️ on and it also just wasn’t a battle that we were willing to tackle and i don’t know we’ll

⏹️ ▶️ see i think this is still also an open question in terms of what other tooling gets built

⏹️ ▶️ and what other things come into the fray because it would be great to have

⏹️ ▶️ better tooling around this it just hasn’t been built out yet and it’s a great opportunity for open source as well

⏹️ ▶️ i was thinking about it the sort of doomsday scenario where like one of these these swift style guide books

⏹️ ▶️ comes out and like it makes some like blanket recommendation that like you should you know

⏹️ ▶️ i always use protocols for this and you should never use classes for that or whatever and it becomes

⏹️ ▶️ wildly popular and accepted as like the bible of how you write swift programming and

⏹️ ▶️ you’re just somewhere shaking your head and going no you got it all wrong but i guess you know we’ll

⏹️ ▶️ cross that bridge when we come to it and i think at this point that the language design itself and the community’s had

⏹️ ▶️ enough influence that that’s not likely to happen but i mean i guess what i was getting at is do you feel like you want to write

⏹️ ▶️ a swiss style god like if you had unlimited time no i don’t think that would be a good use my of my

⏹️ ▶️ time but if i had unlimited time maybe i don’t know it’s hard to it’s hard to answer that theoretical question

⏹️ ▶️ but but also to your concern about somebody came out with a style book that was so wrong

⏹️ ▶️ that would cause me to like you know be really unhappy i actually have a ton of faith in the swift

⏹️ ▶️ community because if something came out that was so weird i don’t think that the community overall would

⏹️ ▶️ would accept it um the community has again just kind of blown

⏹️ ▶️ me away with how cruel they are and how how many great people

⏹️ ▶️ have got involved with swift and swift evolution side of things and it’s been really amazing

⏹️ ▶️ to see these people you know they they go through their own personal trajectory

⏹️ ▶️ on the swift mailing list where you know initially they are saying hi i had this idea what

⏹️ ▶️ do you think and the response is no that’s a terrible idea for this is his reason

⏹️ ▶️ but then they come back and they’re like hey how about how about this did you ever think about this and i was like oh well

⏹️ ▶️ that’s interesting that almost worked but it didn’t work because of that and then they come back and they say hey well what about this

⏹️ ▶️ he said well we actually tried that and we had that for a while and then had to back out and change it this other way because

⏹️ ▶️ we didn’t even think about this other thing and then the next day they’re the ones saying this is the way it needs

⏹️ ▶️ to go and everybody says you’re right we should do that and it’s it’s it’s

⏹️ ▶️ really hard for people that have been involved in the overall design of

⏹️ ▶️ anything as complicated a swift to be able to discern the difference between something that

⏹️ ▶️ is the way it is out of an intentional decision process or the

⏹️ ▶️ way it is as an act an accident of history and so as now that the design

⏹️ ▶️ process is public i think that it becomes a lot easier for people to to tell that and

⏹️ ▶️ it’s very easy for people to kind of understand

⏹️ ▶️ that difference the one big debate that i haven’t actually seen is why is the funk keyword

⏹️ ▶️ the funk keyword and that’s one that luckily we’re now beyond the swift three

⏹️ ▶️ source compatibility threshold so we just can’t have that discussion anymore i think that’ll be

⏹️ ▶️ dan one of the best things of the swift open source thing

⏹️ ▶️ the whole evolution process has is that like the list of questions like the asked and answers questions

⏹️ ▶️ like this is a commonly asked question and we’ve dealt with it before and you’re probably going to want to ask it to here here’s

⏹️ ▶️ but how it was asked before and here’s what the answer is not that everybody’s going to go and see that but i love

⏹️ ▶️ it that exists well and it’s also hilarious that that started out as the commonly proposed list and then

⏹️ ▶️ at some point it became the commonly rejected list right cause if because if it’s commonly

⏹️ ▶️ proposed obviously it’s not getting through and so you have to go to the rejected list if you’re thinking about asking

⏹️ ▶️ to change funk to f n you know

Rust-style memory model?

⏹️ ▶️ um i know you talked about this before but it is worth touching out again because many

⏹️ ▶️ people have have asked me to ask you this um a swift

⏹️ ▶️ and rustle memory model you you phrased it before as an add

⏹️ ▶️ on feature for people who know that they need that type of thing but that it would not

⏹️ ▶️ like the swift wouldn’t become a language in which all memories manage that way instead this would be a special

⏹️ ▶️ purpose feature for particular roles what what roles

⏹️ ▶️ do you think it’s suited for and why why is it not the right memory

⏹️ ▶️ model for all swift well so here’s here’s the way i look at swift in terms of

⏹️ ▶️ memory management today so swift is using arc it’s not using gc um if you want to talk about the

⏹️ ▶️ tree i am happy to do that um that’s its own rat hole we can fall into um

⏹️ ▶️ arc i think is overall an amazing default for swift because it gives you deterministic

⏹️ ▶️ destruction it gives you relatively predictable performance and the arch optimizers

⏹️ ▶️ able to eliminate most of the reference counting operations

⏹️ ▶️ that happen the problem that i see with with art as of today

⏹️ ▶️ or say swift three is that it is not a very

⏹️ ▶️ uncontrollable model and so if for example you have an inner loop and it turns

⏹️ ▶️ out the arch optimizers doing a bunch of retains and releases and you know that

⏹️ ▶️ they’re not necessary because you know the objects are alive there’s nothing that you can really do

⏹️ ▶️ to to solve that problem unless you’re willing to drop down to something like the unsafe

⏹️ ▶️ operations that swift gives you for manipulating references to objects the um

⏹️ ▶️ and so it’s really kind of dissatisfying to me to have a really safe great memory model

⏹️ ▶️ that for performance reasons you have to drop down to un safety right this is a huge cliff and

⏹️ ▶️ is that also a huge complexity cliff that you have to drop into to solve that problem

⏹️ ▶️ and that’s not really great so the promise the dream is to instead

⏹️ ▶️ say hey well if you are a sufficiently advanced programmer and you know how the stuff works well

⏹️ ▶️ the we can give you new options instead of dropping down to unsafe constructs you

⏹️ ▶️ can actually just use more static type information in annotations in your code

⏹️ ▶️ and so you add a few annotations say hey compiler this is ok the compiler

⏹️ ▶️ can then validate those type annotations and check to make sure they’re correct that still memory

⏹️ ▶️ safe is still guaranteed to be ok but you’re paying for it in terms of more of this annotation

⏹️ ▶️ on the code and its more more heavy weight in terms of coding but what you get

⏹️ ▶️ at that is the guarantee that no arc operations are happening once you get to that model then

⏹️ ▶️ it becomes really interesting because you can say hey well in this inner loop i’m going i’ve found in my profile

⏹️ ▶️ that it really does matter for performance and the arco mizer is doing the wrong thing while i can add a few local

⏹️ ▶️ annotations and now the code is fast it’s guaranteed to be fast and the

⏹️ ▶️ clients of my code don’t have to know about it right this is an implementation detail and i think this will really bring

⏹️ ▶️ us to the best of both worlds where you can have memory safety you can have a

⏹️ ▶️ um progressively disclose complex complexity system where most people don’t have to

⏹️ ▶️ know about it or think about it but you can get to really low level performance guarantees that otherwise

⏹️ ▶️ are impossible and once we do this i have a feeling there’ll be certain communities of people that

⏹️ ▶️ will only want to work in this model and these are the communities that like rust

⏹️ ▶️ predominantly so if you’re writing a colonel for example maybe you don’t want to have a reference count your object at all

⏹️ ▶️ and maybe you just want to have um you know you say i will always use

⏹️ ▶️ these annotations of my code pervasively and if if that happens then there’s a couple of options that

⏹️ ▶️ we can investigate we could say hey will if you mark this class with some attribute then that

⏹️ ▶️ that that prevents the compiler from ever doing reference counting and if it would ever do that it just

⏹️ ▶️ raises an error or we could even theoretically have a language dialect mode that said hey produce

⏹️ ▶️ produce an error any time it did an arc operation i don’t like language dialects and

⏹️ ▶️ so we’d have to find a way to handle that maybe it would be a warning and then they would upgrade it

⏹️ ▶️ to an error or something like that but i can imagine doing something like that and once we do

⏹️ ▶️ that then i think you get to a really interesting load where um those systems programming

⏹️ ▶️ type people that otherwise would be using src plus plus cannot use swift and

⏹️ ▶️ that means they only have to learn one language that means that they could use the same tool

⏹️ ▶️ set that you know the id and everything else that works great with swift it means

⏹️ ▶️ that they can scale and use the same language for different layers

⏹️ ▶️ of their stack because many applications have very low level pieces and very high level pieces

⏹️ ▶️ and having them written in different languages is really kind of gross i mean i think

⏹️ ▶️ we’ve seen this in the objective c community where one of the best and most annoying things about objective

⏹️ ▶️ s is that it has s in it right and so this has been hugely important for objective s and

⏹️ ▶️ practice because if you are into a performance problem with obvious message and you can always rewrite that

⏹️ ▶️ algorithm in c and that’s really really really important for objective

⏹️ ▶️ c being successful and you know both in the days of next on sixteen megahertz

⏹️ ▶️ processors but also today for the lot of code that people are writing um

⏹️ ▶️ but it also means that that’s one of the problems that makes it so that objective c and c are so tightly intertwined

⏹️ ▶️ and so that you can’t actually take the part out of objective c without producing a different language

Swift in the browser

⏹️ ▶️ i’m waiting for swift in the web browser because it’s your only escape to begin of applications that have to have one language

⏹️ ▶️ at the higher level different language of the lower one well there there

⏹️ ▶️ that i think is a frontier that is probably the biggest payoff because replacing

⏹️ ▶️ javascript would be such an amazing service to the world

⏹️ ▶️ you and art before it’s been tried yeah but it’s been tried and that’s

⏹️ ▶️ where um you know i’m putting my hope on the asm js the web assembly those kinds of efforts

⏹️ ▶️ were its um enabling languages like swift and swift swift

⏹️ ▶️ compiles to web assembly and asm js both have lvm backends and principals

⏹️ ▶️ somebody could wire up swift to one of those and go to town with it um

⏹️ ▶️ uh if those end up winning and they become a big

⏹️ ▶️ big things then maybe that’ll be good enough but i don’t really know i don’t have my crystal

⏹️ ▶️ ball doesn’t go out to the point where javascript is not in web browsers yeah that’s the difficult part

⏹️ ▶️ is not the not the language mechanics it’s the getting getting something they can understand that in front

⏹️ ▶️ of as many people as possible it’s also very interesting to me so again i’m not a web developer and

⏹️ ▶️ i’m not a i’m definitely not an expert in the space but to me it seems that the trajectory

⏹️ ▶️ of javascript has basically made it into an intermediate language

⏹️ ▶️ it’s not something that developers are writing as much directly as they used to and so i see typescript

⏹️ ▶️ in a lot of other languages that now compile down to javascript and um you know they’re

⏹️ ▶️ really using javascript like like a bit code representation not not a source language that people

⏹️ ▶️ are thinking about as much anymore and so i wonder if in five years you

⏹️ ▶️ know the natural conclusion of that is the javascript is just an asm js type of thing or

⏹️ ▶️ maybe web assembly does take over but but again i’m not the expert i don’t know where

⏹️ ▶️ that direction will go i know that some people love javascript so we’ll see

⏹️ ▶️ on the topic of using languages other than java script to write javascript

⏹️ ▶️ i have to say having done that several times that the tooling boy the tooling

⏹️ ▶️ is not quite where you’d want it to be in terms of being able to write

⏹️ ▶️ and debug and profile in the preferred language and not in the compiled

⏹️ ▶️ down to javascript type language but yeah maybe that’ll be like stage seventeen in the swift

⏹️ ▶️ world domination plan people and i think that’s always been true for preprocessors so i

⏹️ ▶️ mean even in c if you do crazy things the macro preprocessor and c you

⏹️ ▶️ get debugging those things are so horrible and ah that’s

⏹️ ▶️ one of the reasons that we’ve been careful about not adding a macro system swift early it

⏹️ ▶️ just brings lots of interesting trade offs in terms of the bugging and developing and designing

⏹️ ▶️ experience

ABI stability

⏹️ ▶️ one last thing on abi compatibility according to the timelines

⏹️ ▶️ that i heard sketched out that a bi stability could

⏹️ ▶️ be a thing before a sink you know or concurrency stuff

⏹️ ▶️ lands and swift is there any is there any dependencies or chicken egg things

⏹️ ▶️ involving there like in order to in other words in order to do you have to nail down

⏹️ ▶️ some aspects of your concurrency model before you can commit to a bi stability or are they totally orthogonal

⏹️ ▶️ i think they’re totally orthogonal i think the memory ownership model has more of an impact

⏹️ ▶️ on abi stability because there’s some very low level things like how the

⏹️ ▶️ um the getters and setters are co generated for a property

⏹️ ▶️ for example that end up getting impacted by the ownership model that’s one

⏹️ ▶️ of the reasons that were that the swift team is actually actively designing and

⏹️ ▶️ writing work on a proposal for the memory ownership stuff right now it’s not so that it can

⏹️ ▶️ be a swift for feature it’s so that the abi stability work can be done

⏹️ ▶️ in light of the ultimate model for the memory ownership support and

⏹️ ▶️ um i think concurrency is not going to be something that impacts abi stability

⏹️ ▶️ at all but we’ll see and if so then the sufficiently smart programmers

⏹️ ▶️ that work on swift will figure it out and i’m sure it will be great i think it’s also

⏹️ ▶️ an interesting question of whether abi stability will be done for swift four because

⏹️ ▶️ it’s a huge amount of work the work is well under way

⏹️ ▶️ of course but it’s also not clear to me that’s really the the

⏹️ ▶️ right or the most important thing for the swift community and one of the things that ted has

⏹️ ▶️ been a huge champion for and i think he’s right about is that the most important thing right now

⏹️ ▶️ for the swift community is making the compiler more reliable making the air messages better

⏹️ ▶️ making compile times faster and making it scale better

⏹️ ▶️ to large projects and um you know we’ll see how the rest of the before schedule goes

⏹️ ▶️ but i wouldn’t be surprised if at some point they decide that focusing on that is more important

⏹️ ▶️ than nailing ibis stability and swift for

Leaving it in good hands

⏹️ ▶️ so you just mentioned ted that’s that’s ted kreme who is who’s now the lead of the swift project

⏹️ ▶️ is that right yeah he’s the project lead so ted ted has been managing

⏹️ ▶️ the swift and clang projects before that for a number of years he’s been at apple for

⏹️ ▶️ ten years now he’s a stanford phd graduate he built

⏹️ ▶️ single almost single handedly the first clang sack analyzer yeasted

⏹️ ▶️ so so as i love that i’m saying this now as a swift

⏹️ ▶️ developer you know should i be like you know as we saw when you

⏹️ ▶️ announced that you were leaving apple that we saw some of the people in the community asking like should we be worried about swift future

⏹️ ▶️ is swift in good hands now i mean you know it seems like most of us didn’t know ted at least didn’t

⏹️ ▶️ know his name or or weren’t familiar with his contributions it does seem like he’s been doing quite a bit

⏹️ ▶️ there anyway um should we be worried i don’t think he should be worried at all i think swift

⏹️ ▶️ is in amazing hands as is i mean all the things that i

⏹️ ▶️ am leaving behind an apple and quotes are in really good hands and that’s one of the only reason

⏹️ ▶️ i was comfortable in moving on in the case of ted ted is a rock

⏹️ ▶️ star he has been running the swift team and managing them for

⏹️ ▶️ i mean four or five years now um the the rules that

⏹️ ▶️ we had was that ted owned and ran his team and then reported to me and so i

⏹️ ▶️ would mess around and you know cause trouble by you know trying to get people

⏹️ ▶️ to do the exciting important thing that i thought and maybe in line with

⏹️ ▶️ the actually important thing and therefore i’d introduce chaos into the world

⏹️ ▶️ but ted was always the the stable rudder and the one that was really focused on getting the important

⏹️ ▶️ things done and he has a number of really exceptional engineers in the team people on

⏹️ ▶️ the court team like doug gregor john mccall joe joe graff dave abrahams these are all

⏹️ ▶️ just amazingly brilliant people and and also the team includes

⏹️ ▶️ a bunch of other engineers that are equally dedicated and also just totally amazing

⏹️ ▶️ people to work with so the swift team is i think one of apple’s biggest assets

⏹️ ▶️ it’s it’s crazy how brilliant and dedicated they are to the project and how

⏹️ ▶️ excited they are to get to world domination one step at a time

The shoemaker’s language

⏹️ ▶️ coming back to kind of a more broad thing let’s say that and this is not meant

⏹️ ▶️ to be a tongue in cheek reference to your next job this is just in general you know you’re at home your

⏹️ ▶️ kids are in bed you know your wife is out or something like that and you want to just write some

⏹️ ▶️ code you can’t use swift and you can’t use objective c what are you writing code in and i know that’s

⏹️ ▶️ often dependent on what project you’re accomplishing but like what’s interesting to you these days that isn’t swift and isn’t

⏹️ ▶️ objectives oh also i mean i have a ton of different interests i mean

⏹️ ▶️ i really love building ray tracers for example and i’ve done a bunch of stuff like that um

⏹️ ▶️ and i guess if i couldn’t use swift for that then i would probably have to use people i

⏹️ ▶️ i was going to call that but i wanted to give you a chance to not say

⏹️ ▶️ plus plus but i remind people when they when they mention you know what

⏹️ ▶️ is written in right not much sea plus plus and not have your your answers

⏹️ ▶️ plus plus and and you know how much an in personal suffering it causes to have to be writing plus

⏹️ ▶️ all day and building a beautiful world for other people

⏹️ ▶️ that’s where you toil down in the mines yeah yeah it’s it’s a pain and suffering that’s worth it

⏹️ ▶️ for the bigger bigger victory well that’s where swift comes from years having to use see plus plus i can do the same

⏹️ ▶️ stuff but not feel this much pain that’s exactly right i mean there’s a lot of suffering that that led

⏹️ ▶️ to the swift needing to happen um so but but it also it really depends i mean

⏹️ ▶️ maybe if i was doing you know if i was a crazy person i’d use pearl for something i don’t know from that insane

⏹️ ▶️ well well you’d never be able to read it

⏹️ ▶️ though nobody could hey if it’s throwaway code then you never need to read it right

⏹️ ▶️ i’ll just wait i’ll just

⏹️ ▶️ wait for my pearl six grammars to land gently and swift well so i mean that’s another

⏹️ ▶️ that is a great example of a pearl really has nailed the string processing thing

⏹️ ▶️ even in pearl five and i think perl six is even better and swift has a lot to learn from it

⏹️ ▶️ and that’s that’s something where swift or is really learning

⏹️ ▶️ from pearl so ethically is great oh please don’t give him any ammunition this is terrible

⏹️ ▶️ i was enjoying this interview so much until this very moment look look at it this way once this happens john will

⏹️ ▶️ have no excuse oh he will find one nothing

⏹️ ▶️ is so perfect that it can’t be complained about oh my goodness

Dynamic features

⏹️ ▶️ ah this is a perennial topic on the swift marring lists about

⏹️ ▶️ dynamic features and swift that are are

⏹️ ▶️ more dynamic and objectives and less so and swift um in the swift community

⏹️ ▶️ there’s a lot of angst about when if ever will swift allow me

⏹️ ▶️ to essentially you know like what you said before you can write fortran in any language you can write objectives in any

⏹️ ▶️ in any language people will try to write their code in swift but using

⏹️ ▶️ models from objectives that require things like you know

⏹️ ▶️ you know sending messages to objects that you know will receive them but the compiler

⏹️ ▶️ can’t guarantee or you know having big heterogenous collections where you just like know everything’s id and it’ll be fine

⏹️ ▶️ um i don’t even know how to frame this but i

⏹️ ▶️ think that the main question has been are dynamic features possible and

⏹️ ▶️ swift and are they coming and swift or is there some kind of philosophical divide

⏹️ ▶️ where the most dynamic stuff that people really want will never be forthcoming

⏹️ ▶️ not for technical reasons but just for philosophical and safety reasons so so i’ve been

⏹️ ▶️ pretty outspoken about this on swift evolution list so hopefully this isn’t a huge surprise but

⏹️ ▶️ i don’t think there’s any tension between dynamic features and swift the

⏹️ ▶️ a lot of people want to make hay and argue about how it would be impossible to do

⏹️ ▶️ responders pick your future

⏹️ ▶️ the in swift and the the worst case scenario frantic

⏹️ ▶️ blogpost i’ve seen are are things that are along the lines of someday

⏹️ ▶️ apple will rewrite all of its frameworks in swift and then it will be impossible to write res responder

⏹️ ▶️ chains and then bad things will happen and then we’ll be back in the days of mass or some

⏹️ ▶️ other bad things

⏹️ ▶️ on the discussion ends up

⏹️ ▶️ being um i think this blew up most recently right before

⏹️ ▶️ wwdc this year and it was really interesting to watch the blog posts that

⏹️ ▶️ people were flying around because everybody had a different idea of what dynamic

⏹️ ▶️ meant none of them really so

⏹️ ▶️ apple’s not going to counter blog somebody and like

⏹️ ▶️ denounce somebody’s blog on somebody’s post and it’s kind of bad for him to do that but

⏹️ ▶️ i thought it was very interesting and odd that none of those people actually came to the swift evolution list which is the right

⏹️ ▶️ place to do that and asked about it they all just wanted to make these inflamed blogposts to various

⏹️ ▶️ skins um so if you get to my opinion my opinion is that none of those are intention

⏹️ ▶️ with swift’s current design it’s just a matter of prioritization and

⏹️ ▶️ the major problem that swift has is again there’s so much work to do there’s

⏹️ ▶️ concurrency model there’s actors there’s systems programming there’s scripting there’s

⏹️ ▶️ lots of little things that go in there’s better better things for static analysis

⏹️ ▶️ introducing type state in language there’s there there’s pre post conditions

⏹️ ▶️ there are so many things that will be bricks in the house of

⏹️ ▶️ swift that we want to build that need to happen that it doesn’t really make

⏹️ ▶️ sense to spend a lot of time building dynamic features so that apple could theoretically

⏹️ ▶️ someday do something right where the swift team is much more focused on the practical

⏹️ ▶️ necessities of solving the real world problems here and now in front of people and

⏹️ ▶️ um dynamic features like many other things will just kind of flop in place when

⏹️ ▶️ the team has time to design and roll them out and so you will be able to someday

⏹️ ▶️ or i expect that you will be able to reflect over all mat the methods

⏹️ ▶️ in that class has for example today even the swift compilers generating

⏹️ ▶️ all the metadata so you can reflect over all the data members and you and your values

⏹️ ▶️ we just don’t have an api wrapped around that but that metadata is what the ex co memory

⏹️ ▶️ heap viewer uses for example and so there’s a lot of that kind of stuff being put

⏹️ ▶️ in place but um just hasn’t had time to fully bake out yet and when it when it does come in i think

⏹️ ▶️ it’s going to be really exciting and will open more doors for new kinds of patterns that people can do and

⏹️ ▶️ a lot of those will be familiar to objective c programmers but they’ll also be super useful for things that

⏹️ ▶️ people really haven’t done an objectives so i don’t i don’t see a lot of tension there though

⏹️ ▶️ it’s just a priori ation of question i think where where people are coming from is that in

⏹️ ▶️ terms of prioritization because if you’re used to doing things with certain sort of design patterns

⏹️ ▶️ broadly speaking an objective sea and you want to come and implement those same patterns and swift and you find that you

⏹️ ▶️ can’t because you’re lacking some feature it feels like there’s a barrier up and that’s that’s

⏹️ ▶️ getting back to you of writing writing your swift and objective sea style and that’s more of a barrier that they retreat back

⏹️ ▶️ to object to see as i can write it the way i want i to read it right and it works an objective see when i try to write it that way and

⏹️ ▶️ swift it doesn’t work for me your choice is to change the way you write it to be a better fit for what swift has

⏹️ ▶️ or to go back to objective see um so i don’t i don’t agree with that though because um

⏹️ ▶️ swift does support all the features for dynamic dispatch and method lookup

⏹️ ▶️ and everything else that objective c does it just requires you to use the objective c subset

⏹️ ▶️ of the language because it exposes it through the run time right that that’s that’s that’s

⏹️ ▶️ that’s the tension because they’re like oh i want to write it in pure swift like as if there’s something special and

⏹️ ▶️ magical about not using objective c runtime for you know what i mean you do you do get a medal

⏹️ ▶️ for that yeah i guess it makes some people feel good i mean

⏹️ ▶️ there are i can’t really count on that but i just don’t think that it

⏹️ ▶️ that it’s actually fair to say you have to fall back to writing objective seacoast i no no i’m just i’m trying

⏹️ ▶️ to i didn’t write one of these block posts so i’m trying i’m trying to express what i saw in them because that a was lot a lot

⏹️ ▶️ of the conservatives like the they want to do it they want to do it like the new way and the right way and

⏹️ ▶️ part of doing that is not you know objective seeing everything i feel like oh that feels like a compromise in the old way

⏹️ ▶️ so that they’re they are setting their own goalposts for themselves arbitrarily to try to

⏹️ ▶️ enter into this new world and you know they they they want to jump in with both

⏹️ ▶️ feet or not at all and and some of them might end up bailing but i think the i mean

⏹️ ▶️ the way the way i look at it is um i look at that as an area where the language is not

⏹️ ▶️ fully picked out it’s not fully serving their needs and i think that’s really unfortunate

⏹️ ▶️ right and i’m not going to say that i think that that’s not a good thing i want there to be an awesome

⏹️ ▶️ reflection model i want there to be awesome features for sending messages like they’re used

⏹️ ▶️ to i just want to be developed and designed in the right way and at the same time they’re

⏹️ ▶️ being annoyed that they can’t do those things there are a lot of other people being annoyed about compile times

⏹️ ▶️ right yeah no i know and and what what we have to do is

⏹️ ▶️ balance between you know just picking two random things where does the engineering effort go

⏹️ ▶️ and um and that’s never a black and white thing there’s never a right answer

⏹️ ▶️ it’s all based on a gut and judgment and guesses listening the to the community

⏹️ ▶️ talking to people and that’s one of the reasons why i think the swift team is really a

⏹️ ▶️ phenomenal is that it really cares it really cares about what people are doing it read you know the

⏹️ ▶️ various people read the blog post there are people on twitter like the engagement between the team

⏹️ ▶️ and the community is really high because people care and there’s no management dictated

⏹️ ▶️ apple that says that you know this engineer should be on twitter all the time talking to people it’s

⏹️ ▶️ certainly not the case that’s because of passion from the developer and it’s because they really care and i think

⏹️ ▶️ that that’s the thing that is so amazing about the swift team is just a

⏹️ ▶️ how important it is in terms of customer service and understanding understanding what people

⏹️ ▶️ are working through and that insight is what guides the priority

⏹️ ▶️ decisions and guides the trade offs that have to be made all the time because nothing really is

⏹️ ▶️ as clear as you’d like it to be

Community influence

⏹️ ▶️ so building on that when all of us were going back and forth and i was tangentially

⏹️ ▶️ involved with this we were going back and forth but oh it’s swift isn’t dynamic it must be dynamic

⏹️ ▶️ is it fair to say that that does eventually make its way inside of apple just and i’m just

⏹️ ▶️ in that you guys are aware of it that that that that’s talked about in some way shape or

⏹️ ▶️ form because it’s nice to know and i suspect that that it does but it’s nice to know that that

⏹️ ▶️ when the community gets perturbed whether or not that that that feeling is justified

⏹️ ▶️ that at least somebody inside apple has hurt it whether or not they can respond to it at least they’ve

⏹️ ▶️ heard it so when we all get our our our pants all twisted up

⏹️ ▶️ does that does that make it in absolutely i mean the

⏹️ ▶️ there are a ton of people at apple to care about what’s happening in the developer community and and elsewhere right and

⏹️ ▶️ that’s that’s one of the the the things about apple’s approach in terms of not commenting on

⏹️ ▶️ things that can be frustrating because you don’t know but again there’s so many people at apple

⏹️ ▶️ that really do care and that saw it and you know

⏹️ ▶️ again i wish those people that were really worried about it would come to swift evolution

⏹️ ▶️ and ask because then we have a discussion about it but that wasn’t happening for some reason

⏹️ ▶️ but certainly there was a ton of people that saw the blog and i’m sure there are tons of engineers at apple

⏹️ ▶️ that feel the same way and wish the priorities were different and i think that the

⏹️ ▶️ engineering community inside of apple reflects quite closely to the engineering community outside of

⏹️ ▶️ apple as well um and i don’t think that that i hope that’s not surprising

⏹️ ▶️ right all has many different engineers with different feelings and different opinions and and i

⏹️ ▶️ think that’s a really good thing if if it were a super monoculture or something like that that’d

⏹️ ▶️ probably be very unhealthy

RxSwift

⏹️ ▶️ taking a little bit of a turn so i started writing swift almost

⏹️ ▶️ exactly a year ago now and the project that i’m doing at work we’re using our ex

⏹️ ▶️ swift and and quote unquote reactive programming and i’m curious have you looked into

⏹️ ▶️ that at all and do you have any particular thoughts on it does it seem barbaric to you does it seem clever does

⏹️ ▶️ it just seem like an odd choice yeah what what is your take on this whole rx thing

⏹️ ▶️ yes i’ve definitely seen it i have no real world you usage

⏹️ ▶️ experience sure sure most of my opinion is based on reading blogs and reading

⏹️ ▶️ people talking about how awesome it is while not talking about the problems

⏹️ ▶️ from what i gather it seems like it is a way of letting you write a

⏹️ ▶️ lot less code and code that often works better the first time and i can see

⏹️ ▶️ how that’s super appealing it also seems like it’d be really challenging to debug it and maintain it and so i don’t

⏹️ ▶️ know between the two between the pros and cons help balances out um um

⏹️ ▶️ if i were writing a lot of high level lapse i’d probably try it out on an ap or two and see if i liked it

⏹️ ▶️ but um but aside from that i don’t really have a good insight

⏹️ ▶️ either way if it’s the right thing to do or not sure sure absolutely you mentioned a second ago that

⏹️ ▶️ you see some problems and you mention debugging is there anything else that jumps out at you as being a big concern

⏹️ ▶️ or or is it just that it’s so different i mean i’m not afraid of different

⏹️ ▶️ things i think that it’s it’s more of um i mean the questions i’d raise and this is

⏹️ ▶️ out of ignorance not out of sure sure fear but you know what is the community doing

⏹️ ▶️ is there a support line or is the you know is it

⏹️ ▶️ changing and evolving in a way that is good or bad and these are just things i don’t know because

⏹️ ▶️ i haven’t used it but i’ve nothing against the rx community at all and i’ve seen a lot of really cool

⏹️ ▶️ things they’ve done and i’ve read many of the the positive posts in rx and

⏹️ ▶️ in rack native and many of the other things where people are using reactive techniques so and

⏹️ ▶️ reactive cocoa has also been around for quite a while and i mean i think that’s a really interesting application

⏹️ ▶️ that maybe i became a lot easier when swift came out than doing an objective s

⏹️ ▶️ absolutely so i think that it’s great that swift can support different kinds of programming models like that because

⏹️ ▶️ um you know if a awesome new right answer to some problem

⏹️ ▶️ comes out you’d hope that you know that your system can support it and can

⏹️ ▶️ make it really elegant and beautiful

GC vs. ARC

⏹️ ▶️ i feel kind of like this is fighting you know the last war instead of the

⏹️ ▶️ current war but you mentioned garbage collection for sark a bunch of times and obviously

⏹️ ▶️ that ship has sailed but i would love for you to give

⏹️ ▶️ a reasonable summary of what the trade offs were there because object to see had

⏹️ ▶️ garbage collection as you mentioned a sort of yeah i was there

⏹️ ▶️ um and eventually objectives dropped the garbage selection and got ark

⏹️ ▶️ and of course swift doesn’t have garbage traction at all can you talk about the trade offs there and why swift

⏹️ ▶️ is the way it is would you like a comparison of arc against the

⏹️ ▶️ garbage collection objective sea had or garish collection in theory you could

⏹️ ▶️ pick garbage collection in a language perhaps not as burdened as objective with sea backwards compatibility

⏹️ ▶️ but you know that’s worth mentioning as well i think so i think that objectives had a system based on lebara

⏹️ ▶️ lebara had a bunch of implantation concerns and other things that i think don’t

⏹️ ▶️ reflect that don’t obviously reflect onto the ultimate garbage collector

⏹️ ▶️ that you’d ever want to have and so i don’t think the comparing against that is interesting but let me turn

⏹️ ▶️ around so what why do you think our collection is interesting what is compelling about garbage collection beyond

⏹️ ▶️ eric well the idea that memory management is completely out of

⏹️ ▶️ the hands of the programmer and that some magical fairy behind the scenes will make it all good for you

⏹️ ▶️ and that you know obviously what you’re giving up is what you mentioned before that you know even with arc you

⏹️ ▶️ lack some amount of control that you’ll need to to have a language that becomes a system programing language obviously give

⏹️ ▶️ that up with the garbage collection because you’re not gonna be doing assistant shogun language and a garbage collection

⏹️ ▶️ with a garbage collector behind it although i think microsoft tell some projects to do that that singularity project but they

⏹️ ▶️ were trying to build the hall ass off of garbage collection not quite sure how that’s that’s going great but even

⏹️ ▶️ if even if you ignore the the assistance programming side of things because i think it’s fair to say a lot of people

⏹️ ▶️ don’t care about that um so garbage collection is proven in the

⏹️ ▶️ application space for java for example right um and pearl

⏹️ ▶️ but does reference counting come on

⏹️ ▶️ oh that’s right it’s python that uses reference counting plus cycle collector um

⏹️ ▶️ so but let me ask you again so he said it means that you don’t have to think about memory is that true

⏹️ ▶️ well that’s the pitch the pitch is that the programmer doesn’t have to think about it they have to think about it when the garbage

⏹️ ▶️ collector i understand the pitch but is it true when the garbage collector starts doing things you don’t want

⏹️ ▶️ then all of a sudden you do have to think about it but then there’s almost nothing you can do about it so

⏹️ ▶️ so here’s here’s the way i look at it and as you said the ship has somewhat sailed

⏹️ ▶️ i am totally convinced that arc is the right way to go up front it is

⏹️ ▶️ better in a whole bunch of different ways it gives you deterministic behavior so you

⏹️ ▶️ don’t get you know it doesn’t have the unpredictable stutter problem that people like to bash on gc’s

⏹️ ▶️ um the star problem to me isn’t really the issue

⏹️ ▶️ even though that’s what g c haters will bring up all the time it’s more about being

⏹️ ▶️ able to reason about when the memory goes away and the most important aspect of that

⏹️ ▶️ is the art gets rid of finalizer so if you use a garbage collected language you use finalizer

⏹️ ▶️ finalizer are the thing that gets run when your object gets destroyed finalizer

⏹️ ▶️ have so many problems there are entire there’s entire bodies of work

⏹️ ▶️ talking about how to work around problems with finalizer for example the finalizer gets around on the wrong thread

⏹️ ▶️ has to get run multiple times the object can get resurrected while the finalizer is running um

⏹️ ▶️ it happens noted trist cally later you can’t count on it and so you can’t use it for

⏹️ ▶️ resource management for database handles and things like that for example there

⏹️ ▶️ are so many problems with finalizes that arc just defines a way by having deterministic destruction

⏹️ ▶️ beyond that arc though

⏹️ ▶️ so the common another common thing there there are two two arguments

⏹️ ▶️ that people make against arc and in favor of a trace and garbage collector one of which

⏹️ ▶️ is that arc adds overhead because you have retainer release operations that run

⏹️ ▶️ and that is true the other is that you have to think

⏹️ ▶️ about cycles in arc because it doesn’t automatically collect cycles and that is also true

⏹️ ▶️ and that the robot i give to people is that those problems

⏹️ ▶️ are also true in garbage collection just in different ways so in a garbage

⏹️ ▶️ collector for example people don’t think about it but garbage collection injects additional

⏹️ ▶️ code into your application just like arc does and so um you know they’re made different garbage

⏹️ ▶️ collection algorithms not all of them are the same but um the

⏹️ ▶️ most modern garbage collectors that use a nursery for

⏹️ ▶️ short lifetime objects and then promote them out that are generational use something called

⏹️ ▶️ a right barrier and a right barrier is every time you store to a

⏹️ ▶️ property of an object say you have to run additional code garbage collectors

⏹️ ▶️ also need the ability to stop all the threads or at least to be able to stop threads at some point in time

⏹️ ▶️ and they need to be able to do so within a specific time bound because they don’t want the garbage collector to

⏹️ ▶️ take forever the artifact that is the typical garbage collectors in java

⏹️ ▶️ for example will introduce what’s called a safe point into loops and so now

⏹️ ▶️ in your loops extra code is being run because of the garbage collector and

⏹️ ▶️ on more aggressive garbage collection algorithms for example i was reading a blog post recently

⏹️ ▶️ about gos tricolor algorithm um they they are touting the advantage

⏹️ ▶️ of you get really low latency and you get the ability to guarantee

⏹️ ▶️ response times in a more fine grained level than most garbage collectors but to do that they

⏹️ ▶️ use this tricolor algorithm which dramatically lowers throughput and that dramatically lowers throughput

⏹️ ▶️ because they’re doing almost exactly the same kinds of operations that arc is doing

⏹️ ▶️ the problem that it then introduces though is that these operations that the garbage collector is

⏹️ ▶️ introducing are sometimes but not nearly as well optimization as the arch overhead

⏹️ ▶️ that the arc optimizer applies to and furthermore there’s no kind of out on it so

⏹️ ▶️ with arc i think and hope that the ownership model will give people the ability to take control of those

⏹️ ▶️ overheads and if it becomes a problem in practice or if they are just that kind of person they can take full control

⏹️ ▶️ over the lifetime of their objects and then know the arc will never happen in the garbage clutter you don’t

⏹️ ▶️ have that so the performance side of things i think is still

⏹️ ▶️ up in the air because arc certainly does introduce overhead um some of

⏹️ ▶️ that’s unavoidable at least without lots of anita ions in your

⏹️ ▶️ code but also i think that arc has not done yet a ton of energy has been

⏹️ ▶️ poured into research for garbage collection particularly since java has come up there have been hundreds

⏹️ ▶️ of papers written in the academic circles tons of work and hotspot and other

⏹️ ▶️ other java implementations to do different tweaks in different tunings and different

⏹️ ▶️ new kinds of algorithms and garbage collection and that work really hasn’t been done for art yet and so

⏹️ ▶️ i think that there’s still a big future ahead on the programming side of things the cycle

⏹️ ▶️ side of things i think it’s also a really interesting question of how much should people think about

⏹️ ▶️ memory when you when you when i was bathing you a little bit you said that

⏹️ ▶️ the great thing about garbage collection is that you don’t have to think about memory but of course we know that’s not

⏹️ ▶️ true right because if you have a reference to some big object graph that you didn’t mean to keep around maybe

⏹️ ▶️ it’s in your undo stack then you will quote unquote leak that memory right and

⏹️ ▶️ that that’s true of a garbage collector that’s true of arc as well it’s just any

⏹️ ▶️ any automatic memory management approach has that problem and

⏹️ ▶️ so that that is a really interesting thing that there’s

⏹️ ▶️ this question of if you’re building a large scale system do you want people

⏹️ ▶️ to never think about memory do you want them to think about memory all the

⏹️ ▶️ time like they did in object to see classic retain and release may retain release or

⏹️ ▶️ do you want something in the middle and i think the arc strikes a really interesting balance either whether it’s

⏹️ ▶️ in objectives or in swift where i look

⏹️ ▶️ at manuel retainer releases being a very imperative style of memory management or

⏹️ ▶️ male can free all these things where you are telling the code line by line this is where you should

⏹️ ▶️ do a reference count operation this is where you should release the memory this is what you should do at this point in time

⏹️ ▶️ arc then takes that model and bubbles it up a big step and it makes it being it makes it be

⏹️ ▶️ a very declarative model so instead of telling the compiler or the

⏹️ ▶️ yeah telling the compiler that this is the place you should do retain you instead say this is

⏹️ ▶️ an owning relationship and the cool thing about that to me is that not only does that get rid of

⏹️ ▶️ the mechanics of maintaining reference counting and define away tons of bugs by doing that

⏹️ ▶️ it also means that it is now explicit in your code what your intention was and that’s something

⏹️ ▶️ that people who maintain your code benefit from and so by saying that i have a weak point

⏹️ ▶️ or two the parent object of my my thing um that’s a really important

⏹️ ▶️ relationship to know about and as you’re looking at the code you’re maintaining the code having that the explicit is

⏹️ ▶️ very valuable because that talks about the the the relationship between values and

⏹️ ▶️ to me again with the goal of being able to write large scale applications and swift

⏹️ ▶️ i think that’s really useful i also don’t think it’s hugely burdensome though it is definitely part

⏹️ ▶️ of the learning curve of learning how swift works that um you know has to be balanced

⏹️ ▶️ in there as well and so i don’t know i mean i look at it as there are are

⏹️ ▶️ clear advantages in terms of allowing swift to scale

⏹️ ▶️ down to systems that can’t tolerate having a garbage collector for example a few one

⏹️ ▶️ write firmware and swift i think it does provide a better programming model where

⏹️ ▶️ programmers think just a little bit about memory and i think that you know going

⏹️ ▶️ forward it provides a really high performance model that you can get

⏹️ ▶️ better than better than garbage collection in almost every way so i think that in terms of trade offs

⏹️ ▶️ it’s the right one to push forward the other i guess third piece that um

⏹️ ▶️ that garbage collection is really bad about is kind of a show stopper for swift

⏹️ ▶️ which is inner interoperability with sea code so if you’ve ever worked with java

⏹️ ▶️ or with other similar garbage collected languages one of the major advantages

⏹️ ▶️ the garbage collectors give you is that they move objects and they need to do that so they can compact those objects

⏹️ ▶️ so that they can then efficiently do do allocations but the problem is that once you

⏹️ ▶️ start moving objects around if you are interfacing with sea code you can’t have some random sea code

⏹️ ▶️ having a pointer to your object and have it move because then you get a dangling pointer and so

⏹️ ▶️ once you get down that line you end up with things like jay and i the java native interface

⏹️ ▶️ where you have to explicitly pin things you have to maintain them it’s very complicated

⏹️ ▶️ it’s really buggy and art completely defines this away by im

⏹️ ▶️ just saying that okay something’s in memory it has predictable lifetime you

⏹️ ▶️ can reason about it it provides tools for dealing with unsafe pointers and things like that

⏹️ ▶️ and that makes the interoperability with existing sea code but also with objective s and maybe some day

⏹️ ▶️ caples plus code really simple really natural and really efficient and i think that’s a huge advantage

⏹️ ▶️ that art provides that really would be impossible to do with with the garbage

⏹️ ▶️ collector so that’s my opinion i mean i think reasonable people

⏹️ ▶️ just agree obviously but it’s something that does come up now and then or i

⏹️ ▶️ used to come up anyway i’m convinced i think you should use are swift get on that there we go

⏹️ ▶️ chris thank you so very very very much for coming on the show obviously

⏹️ ▶️ we are not an interview show as as listeners have discovered over the last hour or two but

⏹️ ▶️ uh but to take your time on what is presumably a very busy time of your life

⏹️ ▶️ and spend it with us three knuckleheads i really appreciate it and it was very kind of you to do and

⏹️ ▶️ uh you know hopefully this won’t be the last time that we’ll hear you on on a show or maybe even this show we’ll

⏹️ ▶️ see so thank you chris i really appreciate it yeah well thank you for having me i’ve had fun even though

⏹️ ▶️ i’m terrified and probably made a fool out of myself not at all trust me that’s that’s normal i’m still trying

⏹️ ▶️ to get over that plus that’s our job all right thanks a lot to our three sponsors

⏹️ ▶️ this week ero square space and audible and we will see you next week

Ending theme

⏹️ ▶️ now the show is over

⏹️ ▶️ they didn’t even mean to begin because it was accidental

⏹️ ▶️ it was accidental john didn’t do any research

⏹️ ▶️ marco and casey wouldn’t let him because it was accidental

⏹️ ▶️ it was accidental but you can find the

⏹️ ▶️ show now at p dot fm and if you’re into

⏹️ ▶️ twitter you could follow them c a

⏹️ ▶️ s e y l i assess that’s k c s m a r

⏹️ ▶️ c to a r m ant marco roman

⏹️ ▶️ s i r a c siracusa

Post-show: Making splinters

⏹️ ▶️ we didn’t talk about woodworking stuff yeah making

⏹️ ▶️ splinters is fun what what kind of wood was that table made adam it’s it’s walnut

⏹️ ▶️ that’s got to be tough that’s a lot that’s a lot of cutting that’s pretty hard wood right yeah

⏹️ ▶️ i mean it takes time but it’s fun it’s one of these one of these areas where you can learn

⏹️ ▶️ a lot about it over time and keep going deeper and deeper in different spaces and there’s never you

⏹️ ▶️ never know everything so it’s it’s a lot of fun to dive into a woodworker it’s also very very different

⏹️ ▶️ than sitting in front of a computer all day and you actually get to make something with your hands and you get to build a much

⏹️ ▶️ higher chance for dismemberment that that is true that is true then

⏹️ ▶️ i think it’s interesting when when programmers have like incredibly analogue hobbies

⏹️ ▶️ it’s also hilarious because the woodworking community is going through this whole and thing they’re

⏹️ ▶️ not turning it into a very programmed thing and people always say well why don’t you go to

⏹️ ▶️ s and s and do blah blah i’m like but that’s exactly what i’m escaping i don’t want to have to

⏹️ ▶️ program my love that you can’t even escape like the community arguments over standards

⏹️ ▶️ so to make it so you just cut down a tree and you throw it into your workshop

⏹️ ▶️ and then out comes the table yeah well that’s that’s that’s the funny thing about people is that people are all the same

⏹️ ▶️ they just don’t want to notice and agree to that yeah you get to very different communities

⏹️ ▶️ and they think they’re all different but they’re actually the same at root

Post-show: Neutral

⏹️ ▶️ so chris you’re obviously changing careers while not careers necessarily

⏹️ ▶️ changing employers would you consider yourself a car person well that’s a funny

⏹️ ▶️ question i mean i i obviously need a car cart

⏹️ ▶️ but i’m what i consider to be an un car person i want to accelerate

⏹️ ▶️ the path to cars being appliances that solve people’s problems and

⏹️ ▶️ i am personally not the kind of guy who loves doing oil changes and fiddling around with

⏹️ ▶️ them i just want something that is reliable that works ideally drives me to where i want to go

⏹️ ▶️ and i don’t have to think about it it’s just you know solving my problems it’s not something i have

⏹️ ▶️ to care for feed and maintain so that that’s kind of the way i look at cars can

⏹️ ▶️ you drive a stick i did drive a stick before i got my tussle a few

⏹️ ▶️ years ago so yeah it all comes clear now i mean really from the point of view like it of kind of

⏹️ ▶️ sounds like you you want to make cars boring in all in a good way really

⏹️ ▶️ and that’s a noble goal and i think i can see why you went to tesla however

⏹️ ▶️ it is kind of funny that like tesla is in my opinion clearly the most exciting car

⏹️ ▶️ company that the world has known for quite some time and so to go there while while

⏹️ ▶️ having you know such like an almost nonchalant opinion about cars is interesting

⏹️ ▶️ to me yeah well i admit that i never considered going to work

⏹️ ▶️ at a car company before but that’s because i always considered car companies

⏹️ ▶️ to be um you know not not in need of the kinds of

⏹️ ▶️ skills that i bring but autopilot i think is really exciting and really big problem and

⏹️ ▶️ it kind of fits with my my desire to solve nearly impossible problems

⏹️ ▶️ and take on new things and so i’m i’m really excited about it so

⏹️ ▶️ i’m a little curious on that note we’ve talked on this show

⏹️ ▶️ before about you know whether we think that that full self driving

⏹️ ▶️ cars you know basically when and whether we think those will exist like in what kind of time frame are we talking

⏹️ ▶️ a decade are lifetimes ever because you know it’s one thing to make something that can work

⏹️ ▶️ on clearly marked highways it’s another thing that can make something work where john lives where there’s

⏹️ ▶️ where there’s ice all over the road for most of the year and so like there’s no more land markings there’s barely

⏹️ ▶️ any flat road surfaces or you have all these different ambiguities that you have in

⏹️ ▶️ in real world roads do you think you know again obviously

⏹️ ▶️ this is not any kind of official capacity as an about to be tess employee uh

⏹️ ▶️ do you think big picture that we will see completely self driving

⏹️ ▶️ cars capable of driving on effectively all roads within say the next decade

⏹️ ▶️ and if not maybe within our lifetimes yeah i think that it’s very

⏹️ ▶️ possible within the next decade and hopefully that’s a long long a long view

⏹️ ▶️ but keep in mind the goal is to drive better than a human

⏹️ ▶️ and significantly better than a human and i think one of the things that gives me confidence

⏹️ ▶️ in this is that it’s not an even playing field because

⏹️ ▶️ the autonomous cars have more sensors than humans do you know they have they

⏹️ ▶️ have a radar for example and that means that they’re capable of doing things that humans just physically

⏹️ ▶️ can’t and there’s a huge technology problem there’s huge software problems

⏹️ ▶️ this is not an overnight kind of a thing that you wake up and solve immediately

⏹️ ▶️ but i have confidence that could be solved certainly within a decade well the good

⏹️ ▶️ news is it’s not going to take a lot to be better than your average driver from massachusetts

⏹️ ▶️ because that’s a pretty low bar no because they know how to navigate these intersections like seven

⏹️ ▶️ different exits all at different angles some of which are one way none of which are marked so the

⏹️ ▶️ humans can figure that out it’s going to be tough for the sensors say nothing i will drive in manhattan without

⏹️ ▶️ any problems i would never drive in boston oh amen brother i completely agree

⏹️ ▶️ so to bring this back around chris you made mention way early in the episode that you like

⏹️ ▶️ yellow cars what what is

⏹️ ▶️ my my my one of my favorite cars was a yellow mini cooper with black

⏹️ ▶️ hood stripes on it nice and mini cooper convertible it was totally awesome

⏹️ ▶️ um that doesn’t get you in the carpool lane but it was a beautiful

⏹️ ▶️ car in his defense like yellow like i’ve seen like that kind of

⏹️ ▶️ that kind of that category of color like yellow orange maybe teal

⏹️ ▶️ or even like a pink like they’re kind of like bright almost neon ish colors can

⏹️ ▶️ work really well they often don’t but when when they work well they look pretty

⏹️ ▶️ good i could totally see that the only flaw i see in this plan is that tehsil does

⏹️ ▶️ not currently offer either yellow paint as an option or custom paint colors as an option

⏹️ ▶️ what will so now you’ve broken into the real secret they want to hire a compiler guy that’s

⏹️ ▶️ why would you have go in your tesla and yellow if you could have that yes absolutely

⏹️ ▶️ i would have like a giant banana what are you doing

⏹️ ▶️ yeah i hadn’t really fully thought this sir john i

⏹️ ▶️ don’t know if you that are we’re talking about a model s right yeah now i would

⏹️ ▶️ yellow doesn’t seem right for that we to do some photoshop mock ups let’s workshop it a little bit

⏹️ ▶️ we’ll see maybe if you got black stripes down the middle yeah i admit this is a case where details matter

⏹️ ▶️ so yeah no i mean that’s like if there’s any if there’s any way for you to get like a pet feature

⏹️ ▶️ implemented in the model line that seems like a pretty good one to do at least and you

⏹️ ▶️ know i would ask i’m sure i know you’re probably not going to be working on on the bluetooth you

⏹️ ▶️ i but i’m sure you could probably put in a word with the right people to

⏹️ ▶️ please improve bluetooth audio but otherwise if you can

⏹️ ▶️ to make a yellow one i think that would be you know in addition to you know potentially saving thousands of

⏹️ ▶️ lives a year with autopilot software you know getting getting improved bluetooth and yellow option would be

⏹️ ▶️ pretty impressive well yellow would make your car more visible to other drivers other human drivers

⏹️ ▶️ bright colors to know that you’re there since you don’t have a engine sound

⏹️ ▶️ and i have to say this is the most effort i’ve ever done

⏹️ ▶️ to win over one swift programmer

⏹️ ▶️ so i’m not sure if this is a scalable approach

⏹️ ▶️ see other men instead of coming on everybody’s podcast

⏹️ ▶️ and talking to them individual my god that’s amazing