5 ms·
Why not Go? It's more portable.
by anthk 11mo ago
Why not Go? It's more portable.
- hu3 11mo agoand easier to learn. and better funded. and easier to find devs.
- ramon156 11mo agoThey both suck getting new devs for Also, just because it's part of Google doesn't make go better funded. Theyd probably be fine killing go. Definitely easier to learn though :P
- FieryMechanic 11mo agoGo been around for quite a while now. It isn't going anywhere.
- vablings 11mo agoRust has been around for over 10 years now. In the last five years the language hasn't changed much and has gotten better and better
- FieryMechanic 11mo agoI didn't like Rust one bit and gave up learning it. Go on the other hand is quite nice.
- hu3 11mo ago> They both suck getting new devs for I'm willing to be Rust suck a ton more to hire devs. Since, as we both agree, Go is easy to learn. Any C#, PHP or Java dev can get going with Go in not time.
- agumonkey 11mo agoi have no dog in the fight, but based on tor release schedule it seems to me that the team is very very talented and rust complexity is not a challenge for them
- tjpnz 11mo agoRust is going to feel more familiar to Tor contributors than Go. Based on the list of platinum members (which includes Google and Tor btw) there's some serious money going into the Rust Foundation, assuming it's managed properly I can't see funding as an issue. https://rustfoundation.org/members/ https://rustfoundation.org/members/
- preisschild 11mo agoWhat do you mean? Rust supports far more platforms. Also Rust has a lot more inherent safety features than go. (I think Go is great and its my primary language)
- superkuh 11mo agoIn terms of compilation of programs Go is far, far easier than Rust. For Rust to compile a random Rust program on the internet one almost always has to have the absolutely latest out of repo compiler toolchain from curl rustup.whatever | sh. The normal 4 year release cycle is incompatible with rust development. For commercial use cases this doesn't matter. But for open source like the tor project it does. That said, since they use Firefox this bridge has already been burned.
- norman784 11mo agoAFAIK if the project has a rust-toolchain.toml[0] file, cargo will download the correct compiler for the project. [0] https://rust-lang.github.io/rustup/overrides.html#the-toolchain-file https://rust-lang.github.io/rustup/overrides.html#the-toolch...
- anthk 11mo agoNo Rust under OpenBSD i686. Rust on PowerMacs? Alpha?
- lynndotpy 11mo agoDon't Rust and Go build to mostly-statically-compiled binaries? (With the exception of a link to libc.) (This isn't a rhetorical question, this is something I don't know a lot about I'd imagine the biggest cultural reason is that many Rust developers were C developers who had a reason to find something better, but still scoff at garbage collection, large runtimes, etc. They probably have a lot more Rust expertise in their circle. Another technical reason is that they were trying to replace their C code with Rust in bits and pieces before they went with a full rewrite. I don't know about Go, but this is something ergonomically doable in Rust.
- atq2119 11mo agoPlus, Rust has a more expressive type system. I like loose type systems for some quick scripting, but I started to adopt Rust for many of my personal projects because I find it's so much easier to get back into a project after a year when there are good type system guard rails.
- johncolanduoni 11mo agoRust can create statically-compiled binaries on Linux by using musl instead of glibc, but it’s not the default like it is in Go and is as a result not quite as effortless. There are a lot of crates with native dependencies that require slight environment tweaks to work on a musl build. Go on the other hand goes to great lengths to not need to link to any C code at all, to the point of shipping its own default TLS library and cryptographic primitives.
- lynndotpy 11mo agoI thought the default for both Rust and Go were to statically compile everything except the dynamic link to libc? And that you could optionally statically include musl with a bit of extra work. I've never had to do anything unusual with building, but I thought the "almost-ststically-compiled" thing was somewhere Go and Rust were almost identical.
- steveklabnik 11mo ago
- pezezin 11mo agoPortable to what? Rust works fine on all of today's popular platforms. I see people complaining about Rust's lack of portability, and it is always some obsolete platform that has been dead for 20 years. Let's be serious, nobody is gonna run Tor on an old SGI workstation or Itanium server.
- vablings 11mo agoIt is still possible to build for targets such as Itanium. There is nothing stopping you from writing your own targets too in LLVM and its not obscenely difficult https://github.com/llvm/llvm-project/tree/main/llvm/lib/Target/M68k https://github.com/llvm/llvm-project/tree/main/llvm/lib/Targ...
- edm0nd 11mo ago>Let's be serious, nobody is gonna run Tor on an old SGI workstation or Itanium server. dont temp me with a good time and awesome weekend project!
- yjftsjthsd-h 11mo agoThat's a good point, really there's no reason to waste time on anything but popular platforms. Obviously, of course, this means dropping support for everything except Windows (x64 and maybe ARM) and macOS (ARM). (\s) In all seriousness, I guess you can make this argument if you only care about Windows/macOS, but the moment you run anything else I have to ask why, say, Linux deserves support but not other less-common platforms.
- pezezin 11mo agoBecause: 1) Development resources are finite. 2) Linux runs all of the world supercomputers, most of the internet infrastructure (server, routers, etc), most of the cellphones (Android), and lots of other things. Its global marketshare is way bigger than macOS and all the BSD put together.
- anthk 11mo agoTry living without OpenSSH and the rest of *BSD contributions.
- deleted 11mo ago[deleted]
- anarki8 11mo agoProbably because: - better data race handling; - no garbage collection, more predictable performance; - stricter type system that can enforce constraints better; - closer to metal and better FFI support. Which seems to matter more for Tor project than support for some barely used platform.
- timeon 11mo agoThis is legit question, especially for Tor binaries. Advantage of Rust (or original C implementation) is for users that do not have runtime and want to import Tor libraries (like arti-client) in their code. Go could work but those unmanaged languages are better here. So in the end Rust (or C, C++ etc.) can serve more user-cases.