Hacker News new | ask | show | jobs
by jamil7 1577 days ago
It shares that as well as horrendous compile times with Swift.
1 comments

The irony being that while C++ is known for its compile times, the ecosystem relience on binary libraries makes it much more tolerable.

Microsoft is also shipping pre-compiled projections for Rust/WinRT.

Then we have examples like image, that compile rayon twice, with different versions, because we just love to watch third party crates being compiled.

However I should also add that compile times have improved greatly, my travel netbook can finally handle small Rust projects without killing the battery.

C++ binary libraries are a disaster. At least Rust is honest and tells you to just fall back to the C ABI for interop, and rebuild high-level abstractions around it in code that's built with the project - much like a 'header-only library' in C++.
I beg to differ, and until Rust community acknowledges they are relevant, there are industry domains where C++ will keep its dominance.
Take a look at the C++ community discussion around the feasibility of "ABI breaks". The C++ community is acknowledging the issues, and how they're getting in the way of continued "dominance" in many sectors.
I am fully aware of them, a vocal minority that only cares about FOSS libs.

Why do you think Apple has spent such a big effort making Swift work for shipping binary libraries?

Most devs would just stick with Objective-C, C and C++ otherwise.

> Microsoft is also shipping pre-compiled projections for Rust/WinRT.

Eh, sort of. They're basically shipping the Rust equivalent of C header files and import libraries. Whereas before they would parse metadata in a build script which would then generate the Rust code on the fly (which was hell for a number of reasons). And the installed Windows SDK was used for the import libraries.

Nope, I was speaking about this,

https://github.com/microsoft/windows-rs/tree/23ff38bbbf46fb5...

Apparently since last November they decided to replace it with another approach, so my information is outdated.