Live data from Hacker News

Apple is open sourcing Swift Build

swift.org

51–60 of 300 posts

Re: Apple is open sourcing Swift Build

#51
post #43
post #23

Earlier quoted context omitted.

Is it really being released? Although some parts of the language and build chains are technically open source (as in, you can see the code), the project is still completely controlled by Apple at the top.

You are wrong about "some parts" - you can browse github.com/swiftlang to find out. About control - serious question: how is this different from for example Rust, Go, Zig or Python? For each of those you can submit a change proposal through an official process and you can submit code changes through a pull request. But also for each of those there is a non-zero chance that a smaller group of people who do governance…

> About control - serious question: how is this different from for example Rust, Go, Zig or Python?

You can ask Chris Lattner about how many many changes were forced through the language before they were ready, or even properly designed, because Apple needed them: https://www.youtube.com/watch?v=ovYbgbrQ-v8

Re: Apple is open sourcing Swift Build

#52
post #2

Is Swift actually serious about embedded?

Of course! Tons of examples here: https://github.com/apple/swift-embedded-examples At WWDC24, we shared a session on embedded Swift, which is available on YouTube: https://www.youtube.com/watch?v=LqxbsADqDI4 More documentation on embedded Swift tooling here: https://github.com/swiftlang/swift/blob/main/docs/EmbeddedSw... (Disclosure: I work at Apple.)

Encountering an Apple employee in the wild is like spotting a unicorn.

Re: Apple is open sourcing Swift Build

#53

Earlier quoted context omitted.

I feel like Swift is being held hostage by Apple. I can't get get the next version of Swift, because it's being distributed with a higher version of Xcode that only runs on an OS version I don't want to install (yet), and even if I did, I'd first have to buy a new Mac for that. That trick seems to work with enough developers to make Apple ever more rich and powerful and even more arrogant (if that's possible at all),…

While i am sympathetic to you, you have to see that you represent a vanishing small use case for them.

Isn't that their complaint though? They don't want to participate in a language where they can only ever be a second class citizen.

Re: Apple is open sourcing Swift Build

#54
post #4

The goal for Swift should (and seems) to be to gradually separate itself from XCode, which is holding it back from its ambitions. XCode has been compared to many things, but at 3.1 stars on the App store, one must find that it is still slightly overrated.

I feel like Swift is being held hostage by Apple. I can't get get the next version of Swift, because it's being distributed with a higher version of Xcode that only runs on an OS version I don't want to install (yet), and even if I did, I'd first have to buy a new Mac for that. That trick seems to work with enough developers to make Apple ever more rich and powerful and even more arrogant (if that's possible at all),…

This isn’t true, you can get the next version of Swift by downloading a pkg installer from https://www.swift.org/install/macos/

You can get it bundled with Xcode as well if you’d like, but it’s not necessary.

Re: Apple is open sourcing Swift Build

#55
The article doesn't mention the differences with current swift package manager build system. The repository doesn't mention it either, just saying that swiftpm can use the new build system by adding an argument. Anybody does what does this actually changes? Does it improve something for non-Apple platforms?

Re: Apple is open sourcing Swift Build

#56
The discussion here reminds me so much of early C# days. It was being touted as open source and cross platform back then, and Microsoft even hired a top GNOME developer to port it to Linux and GNOME was going to be rewritten in C#. It was going to be amazing. Never quite panned out.

Re: Apple is open sourcing Swift Build

#57
post #2

Is Swift actually serious about embedded?

Apple probably has use cases for this and they’re bringing it into the open as a nice marketing thing. I wouldn’t count on long term support or compatibility beyond current priorities for Apple (same as their other SDKs for iOS, macOS etc).

Re: Apple is open sourcing Swift Build

#58
post #22
post #14

Earlier quoted context omitted.

Distro packaging for programming language ecosystems is so often hopelessly out of date. I’ve never used a distro toolchain or packages to build production software for any language Python’s age or younger. Outside of C/C++/Fortran pretty much every project I see on Github prefers things like Rustup or Nix for toolchains to navigate around Debian/Ubuntu/RHEL’s “stability” approach.

I disagree vehemently. For any active language, distro packages should be at most 3 years old. And for any language that's stable enough to be worth using, "3 years old" is good enough.

Both GCC and Clang have shipped support for major updates to C and C++ within the last 3 years. If C and C++ aren't stable enough, what is?

Re: Apple is open sourcing Swift Build

#59
post #47

Earlier quoted context omitted.

I doubt Apple really cares much about competing with other languages, tooling, or platforms when it comes to Swift or Xcode. They have a completely captured audience and ecosystem, and anything beyond that isn’t even a "best effort" — it's more like, "You're welcome to see if it works for you, but don’t bother us if it doesn't."

I don't know about Xcode, but Swift is open source with an active community so if it doesn't work for you then you can definitely bother the Swift Open-Source project with a pull request or a proposal for a language or tooling improvement. You can also have a discussion on the forums or in the bug tracker with fellow contributors. You can also make the change in your own fork and use that. This is exactly how for exa…

Scooby doo meme

“let’s see who you really are”. . Apple employee.

Re: Apple is open sourcing Swift Build

#60
Swift is a really cool language.

But one thing that blows my mind is that if you ever encounter an "index out of range" error, the (massive) error message that you get doesn't tell you anything about where this error occurred... no line number... no nothing...

    let a = [1]
    print(a[1])
Is all you have to do to reproduce the error.

The error looks something like that https://pastebin.com/MQV82SaR

And gives you no useful information as to how it happened or how to fix it.

compare that with Golang which tells you, it happened in main.go at line 4.

    panic: runtime error: index out of range [1] with length 1
    
    goroutine 1 [running]:
    main.main()
     /Users/username/main.go:4 +0x15
    exit status 2
EDIT: with the LLVM_SYMBOLIZER_PATH set https://pastebin.com/8M9Dbrgj this doesn't provide anything useful either.
Post reply on HN