News for hackers. Stuff that matters.
Re:Why we chose Rust by fwip on Thursday June 20, 2019 @06:58PM (#20238259)
I'm surprised to see that Go wasn't considered. While not as lean and mean as Rust, it also has excellent support for parallelism and safety, while being easier to get into.

Edit: For clarity, I'm not saying Go is the best choice. But when Lua, Python, and Java are in the running, it's surprising that Go wasn't. Especially when the article calls out the learning curve of Rust as a downside.

Re:Why we chose Rust by 0815test on Thursday June 20, 2019 @07:04PM (#20238298)
Well, Go has excellent support for parallelism and excellent support for safety - whereas Rust actually supports parallelism with safety. Rust is also gaining lots of useful "tweaks" that will make it quite a bit easier to get into in the future - and the syntax alone is a big draw to former Ruby, Python etc. programmers, while you really can't say the same about Go. Now, of course Rust is not for everything (some things really can't be done without efficient GC, and Go gives you that), but it looks like these Bitbucket users made a very solid choice here.
Re:Why we chose Rust by reificator on Thursday June 20, 2019 @07:23PM (#20238449)
> it looks like the Bitbucket folks made a very solid choice here.

Just a heads up, this is not from the bitbucket team. That's just where it's hosted.

Re:Why we chose Rust by harikb on Thursday June 20, 2019 @07:22PM (#20238446)
> Author bio: Mohit Agrawal is a software developer from Indore, India and works at Oviyum Technologies, an outsourced product development firm

Not sure why bitbucket is promoting this particular guest post.

Re:Why we chose Rust by apta on Thursday June 20, 2019 @11:20PM (#20239617)
> has excellent support for parallelism

concurrency, not parallelism, and even there it doesn't have anything similar to immutable data structures or java.util.concurrent or System.Collections.Concurrent

> support for safety

Not more than any other available GC'd languages.

> some things really can't be done without efficient GC, and Go gives you that

Only if you care about pause times at the expense of throughput, and you don't have to deal with very large heaps

Re:Why we chose Rust by hackcasual on Thursday June 20, 2019 @07:02PM (#20238276)
It's for an embedded (SoC) device, so likely they didn't want the overhead of a more managed language.
Re:Why we chose Rust by dom96 on Thursday June 20, 2019 @07:06PM (#20238323)
and yet they include Python in the comparison?
Re:Why we chose Rust by cyphar on Thursday June 20, 2019 @10:01PM (#20239241)
MicroPython is a wholesale rewrite of Python to be suitable for microcontrollers. From memory, the ESA (European Space Agency) uses it for some of their projects.
Re:Why we chose Rust by randyrand on Thursday June 20, 2019 @07:17PM (#20238404)
He never said it was embedded.
Re:Why we chose Rust by reificator on Thursday June 20, 2019 @07:20PM (#20238426)
> He never said it was embedded.

> We needed a language that was fast enough to allow minimum real-time latency and use limited resources of a SoC device.

Re:Why we chose Rust by flukus on Thursday June 20, 2019 @11:27PM (#20239647)
SoC also describes a modern phone, rasberry pi, probably even some modern laptops/netbooks. I think it's generally agreed that these are not embedded devices, but the line used to be much blurrier.

It sounds like the evaluated their options, added in a few that they were never really going to consider anyway, came to the conclusion that C++ was best but then made up some reasons to use rust anyway.

Re:Why we chose Rust by solipsism on Thursday June 20, 2019 @07:02PM (#20238286)
It's a real stretch to call Go's support for memory safety "excellent".
Re:Why we chose Rust by monocasa on Thursday June 20, 2019 @07:05PM (#20238309)
Strictly speaking, it is memory safe with the exception of storing pointers in atomics and unsafe calls AFAIK.
Re:Why we chose Rust by Jweb_Guru on Thursday June 20, 2019 @07:14PM (#20238376)
Sending slices over channels can cause UB.
Re:Why we chose Rust by chessturk on Thursday June 20, 2019 @07:37PM (#20238543)
Do you have an article on this? I didn't know that was possible.
Re:Why we chose Rust by vlovich123 on Thursday June 20, 2019 @07:04PM (#20238296)
> minimum real-time latency and use limited resources of a SoC device.
Re:Why we chose Rust by apta on Thursday June 20, 2019 @11:16PM (#20239598)
> support for parallelism

It has support for concurrency, not parallelism.

> and safety

It's not any safer than other GC'd language available today, and likely quite less so compared to languages with immutability and proper persistent data structures in them (Scala, Java, F#, etc.)

Re:Why we chose Rust by bsaul on Friday June 21, 2019 @04:11AM (#20240791)
I’m curious what you mean by « no support for parallelism » ?

Goroutines are scheduled on different processors, and do run in parallel.

Re:Why we chose Rust by apta on Monday June 24, 2019 @12:57PM (#20265654)
It's at the discretion of the runtime though. With native threads you have more control. And you can have several goroutines running on the same processor concurrently.