Live data from Hacker News

“Swift will be open source later this year”

apple.com

501–510 of 573 posts

Re: “Swift will be open source later this year”

#501
post #468

Earlier quoted context omitted.

The success of UNIX is inseparable from C and vice versa. C made UNIX one of the first portable operating systems and, by virtue of being low-level, provided performance.

The same could be said of OSes using Algol and Mesa. They just hadn't successful startups using them.

There are good reasons that these startups weren't using OSes using Algol and Mesa. You seem to imply that the success of C and Unix is some historical accident as a result of two startups picking Unix randomly, and their choice was bit a function of the technical properties of UNIX and C. Which, is of course, nonsense.

Sun used Unix because Sun was co-founded by Bill Joy. By that time, Joy was already deeply involved in Unix (per BSD). If he didn't find Unix and C likeable and up to the task, they would have made different choices.

SGI and Sun were just one of many catalyzers, like a lot of programming languages have catalyzers.

Re: “Swift will be open source later this year”

#502

Earlier quoted context omitted.

This is a great tip. My main laptop is a 2009 white MacBook with an SSD I cannibalised from another old laptop. The only thing I miss is Civilization V, everything else is fine.

Doesn't Civ V run on Mac as well ?

Yes, but probobably not on a 2009 MacBook.

Re: “Swift will be open source later this year”

#503
post #499
post #473

Earlier quoted context omitted.

Good luck with that. One of the reasons JS is the lingua franca is that every browser comes with a JS runtime, all you need to get started is a plaintext text editor and all you need to publish an "app" is cheap/free web space. Mark my words: Swift won't replace JS, not even PHP. EDIT: Also, what's the point of writing Swift code in Linux if you aren't developing for iOS? As a non-iOS developer nothing at all compels…

The point on having Swift on other platforms means you can write software for things other than iOS/OSX. It's a fun, modern language that brings A LOT to the table that js/py/rb don't (type checking and the ability to distribute binaries, for starters).

But programmers don't want better languages[0]. Programmers mostly just want what they already have. You can't overcome that kind of resistance just by saying "look, here's a language that's more fun and modern".

Programmers say they want better languages, but good luck trying to convince them to switch to a new language just by its merit. The only tangible benefit of Swift is that it can be used instead of Objective-C for iOS -- which is important for iOS because Objective-C poses an even bigger hurdle by virtue of its unfamiliar syntax. Swift wins on iOS because it competes with a language nobody wanted to learn to begin with.

Even as far as familiarity goes, the only thing Swift looks familiar to (based on first impressions) is Ruby, except it uses a more familiar C-like syntax (i.e. braces). While Ruby programmers are extremely visible (especially in startup/valley crowds) there aren't that many of them -- not to mention that some have already moved on to Rust or JS.

0: https://www.youtube.com/watch?v=JxAXlJEmNMg

Re: “Swift will be open source later this year”

#504
post #468

Earlier quoted context omitted.

The same could be said of OSes using Algol and Mesa. They just hadn't successful startups using them.

There are good reasons that these startups weren't using OSes using Algol and Mesa. You seem to imply that the success of C and Unix is some historical accident as a result of two startups picking Unix randomly, and their choice was bit a function of the technical properties of UNIX and C. Which, is of course, nonsense. Sun used Unix because Sun was co-founded by Bill Joy. By that time, Joy was already deeply involve…

You just confirmed what I said.

The startups that have chosen UNIX, did so because the owners were part of the American UNIX university culture.

A different background would have mean a very different history in mainstream OSes and their respective system programming languages.

In Europe C had very little meaning until most enterprises started to replace their mainframes by UNIX servers from those companies.

Re: “Swift will be open source later this year”

#505

Swift for me is what Python3 should've been. For me as a Python user, this development is huge. I've been watching for the language to move to instead of Python3. Of Rust, Go, Swift and other new languages, Swift always seemed to me the most appealing language. Being the 1st class citizen on iOS makes learning this for serverside development very appealing. An ideal server language that enables single language client…

... or you could just move to coffeescript and have something even more clay-like than python running everywhere.

its still javascript with its quirky behavior in the end.

Re: “Swift will be open source later this year”

#506
post #472

Earlier quoted context omitted.

Though there might be much to say about the different implementations of generics , I've found them to be easy to understand and use in languages. No type theory required. That has been more like "Oh, so that's the name for that thing/aspect, neat". If I don't have a problem with that, those coveted master race Google developers should have absolutely no problem with it.

It's not that generics are hard to grok, it's that they get used in a hard to grok way. Wrapping your head around such things gets more and more hard as the app complexity grows. The base point is that languages like Go let you think of the program at runtime, only. Types are a runtime concept, everything is a runtime concept. Structuring APIs to use compile time safety requires a whole other kind of thinking, one wh…

Right, don't have to think about compile time. Instead they sometimes have to think about post-compile time[1], i.e. code generation. Now you don't have to think about those weird bracketed capital letters. Just take care to check where you have comments[2] that happens to include directives to some external tool.

With how Go programming seems to work for some people, I can perfectly well imagine a system with commands that do code generation as a hook for other commands, or by 'listening to the file system' for changes in certain files. That could get out of hand pretty easily. And yeah, one can say "anything can be taken too far". Just like you said about generics. The difference might between having well-encapsulated and behaving mechanisms that does most of what you normally would need. As opposed to a "simple" system that just pushes the problem to another level, in more ad-hoc ways.

[1] I honestly don't know if the code generation typically is pre-, post-compile or a mix of those two. It's too complex for me.

[2] I thought single-line comments was supposed to be a safe haven...

Re: “Swift will be open source later this year”

#507

Any predictions how this can hurt RoR,nodejs and the others ?

Well Node.js(+Framework) is an entirely different beast from Swift(+Framework), RoR, Python+Django, etc. As for Swift(+Framework) vs Python+Django, RoR, etc, Swift would have to be faster and introduce some amazing new feature for it to replace anything. I dont personally like how Swift is statically typed but does type inference. If i dont specify a type for my variable i should be able to change my variable's value…

Stupidest argument i've ever heard in favor of javascript.

> If i dont specify a type for my variable i should be able to change my variable's value to whatever type i want.

Re: “Swift will be open source later this year”

#509
post #421
post #350

Earlier quoted context omitted.

As much as I like Swift, without real garbage collection I wouldn't want to use it an any enterprise project. Keeping track of ownership of reference counted objects shared between who knows how many other objects sounds like a nightmare.

There's nothing to keep track of, all reference counting is handled through ARC which is built in to the compiler.

I'm referring to cases where you have to use unowned, etc, to break reference cycles. The larger the application the harder it is to find these issues.

Re: “Swift will be open source later this year”

#510

Earlier quoted context omitted.

Supporting Linux is a surprise, but I think it's a great move on their part. Think: How many iOS apps are frontends to a server API? And how many of those APIs are running on Linux servers? Swift on Linux means ~all the code for a client-server iOS app can be written in the same language.

The fact that I don't use OSX has been a barrier to getting better at iOS development. Hackintoshing has proven to be quite elusive and the vmware and vbox USB layers in Linux don't convince virtualized OSX enough to transfer over apps to my iDevices. I'm not convinced you can get to high quality by testing strictly on emulators. If anyone has an old mac that can run modern xCode (you probably know what this constitu…

> Hackintoshing has proven to be quite elusive

I've been using a hackintosh since 2008. It's literally never been easier to get one up and running.

Post reply on HN