Live data from Hacker News

Rust is Software's Salvation

redox-os.org

151–160 of 182 posts

Re: Rust is Software's Salvation

#151

Earlier quoted context omitted.

Borrow checker learning curve is an issue, of course. But not checker itself.

You do realise you've wasted both my time and your own. If you thought about it from the start, it's obvious that I was referring to the learning curve. All facets of all Turing-complete languages are useful once you've overcome the learning curve. What varies is the length of time needed before you become proficient in using it. For another example... The learning curve for manual memory management in C is a major i…

No, I think I made important distinction. There can be issue with technology and there can be issue with learning curve.

Re: Rust is Software's Salvation

#152

Earlier quoted context omitted.

No one's being driven away. Only people who had no intention on trying Rust are complaining about it.

There's plenty of comments about it in the Rust subreddit, coming from people who have tried it. Look, it's not an issue for all time, there are plans to improve it, I'm just suggesting it as a point of friction right now. If you seriously don't think it's an issue, what would you say are the issues? You won't do yourself any favours if you try to pretend Rust is perfect.

I've been writing software exclusively in Rust since the 1.0 release. I have no issues with the borrow checker, personally. I haven't seen the borrow checker mentioned as an issue on the Rust subreddit, which I frequent.

The only people who have issues are people who've used Rust for less than a week and still do not understand the basic rules of the borrow checker. I've explained it many times to people already. Once you know the rules, it's easy peasy, and you'll never have another complaint from the borrow checker ever again.

The only improvements that I could see for Rust is landing non-lexical borrows, macros 2.0, and faster compile times, albeit compile times are largely fixed now. A 100K combined LoC project can easily compile a release build using 1 core in 3 minutes or less.

Re: Rust is Software's Salvation

#153

Earlier quoted context omitted.

You do realise you've wasted both my time and your own. If you thought about it from the start, it's obvious that I was referring to the learning curve. All facets of all Turing-complete languages are useful once you've overcome the learning curve. What varies is the length of time needed before you become proficient in using it. For another example... The learning curve for manual memory management in C is a major i…

No, I think I made important distinction. There can be issue with technology and there can be issue with learning curve.

The article I shared with you previously was about the learning curve.

Re: Rust is Software's Salvation

#154

Earlier quoted context omitted.

> The issues with the software/computing world are bigger than array bounds checking and type correctness. Annoyingly, these bugs still bring down our systems in an age when we're on the verge of self-driving cars. Can you imagine that? Your car can crash because somewhere a programmer messed up a simple bounds check. By removing the possibility of these small annoying bugs, you leave the programmer free to focus on…

Again, I get where you are going with this. Rust isn't the only solution. There are mechanisms that can be used in C++ to make a program memory safe by construction. I'm not even saying that Rust isn't a good solution. (I am saying I don't like the syntax...I'm sure I could get used to it at some point.) I just get very wary when something has this kind of "evangelism" behind it. That's all. I'm really looking forwar…

Would you mind sharing other "correct by construction" ideas/references/libraries you know ?

Re: Rust is Software's Salvation

#155
post #34
post #19

Earlier quoted context omitted.

>It's worse than the phase Java went through when it hit its peak. As a person who lived through the 1990s Java hype and had a bookshelf full of the official Java books (Addison-Wesley white books)[1], the Rust evangelism is nowhere near that level. To refresh the memory, 1990s Java evangelists predicted: 1) C/C++ would become obsolete because in the age of abundant desktop resources (cpu power and more RAM), the GC…

Many of those failures were more political than technical. For example, the internal wars between Windows and DevTools divisions at MSFT, were the biggest reason for Longhorn's failure. MSR with Midori has proven the viability of using C# for systems programming, when no politics are in play and everyone is focused on technical improvements.

Has Longhorn failure been documented publicly ? I'd love to read about it in details.

Re: Rust is Software's Salvation

#156

Earlier quoted context omitted.

There's plenty of comments about it in the Rust subreddit, coming from people who have tried it. Look, it's not an issue for all time, there are plans to improve it, I'm just suggesting it as a point of friction right now. If you seriously don't think it's an issue, what would you say are the issues? You won't do yourself any favours if you try to pretend Rust is perfect.

I've been writing software exclusively in Rust since the 1.0 release. I have no issues with the borrow checker, personally. I haven't seen the borrow checker mentioned as an issue on the Rust subreddit, which I frequent. The only people who have issues are people who've used Rust for less than a week and still do not understand the basic rules of the borrow checker. I've explained it many times to people already. Onc…

It took me quite a bit longer than a week to completely internalize the borrow checker. Probably closer to a small number of months. I still sometimes run into problems, but I have enough experience now to know what the space of solutions looks like.

Let's be careful not to overstate Rust's benefits and understate Rust's costs. Of course, I do happen to think the benefits are overwhelming compared to the costs. :-)

Re: Rust is Software's Salvation

#157
post #60
post #29

Earlier quoted context omitted.

It is, especially if these checks are done at compile time, not at runtime.

How can checks be done if the size is dynamic based on run-time data?

"Integer between 0 and n-1 inclusive" is the type of valid indices for an n element array. The trouble is most languages don't have type systems that allow expressing that.

Re: Rust is Software's Salvation

#158
post #30

Earlier quoted context omitted.

And this is getting nauseating even to these wanting to give it a try. I'm in the step of walking away and forget about it until the dirt settles down (and it becomes at least as fast as C/C++ or... even Go)

I was competing against some C and C++ software developers in Advent of Code with efficient solutions, and my Rust solutions came out faster each time. Might want to check your facts.

That doesnt mean anything. Try a little real software for instance.

Re: Rust is Software's Salvation

#159

Earlier quoted context omitted.

I think you'll find a lot of Rust's supporters actually come from a Systems Programmers background who've felt the pain before. I've been doing C/C++ for close to 15 years now, I find that the borrow-checker not only helps with safety but also with guiding a good architectural foundation. Nothing keeps you from dropping into an unsafe block and cranking out very c-like code if you want as well. All my green-field cod…

I have too but I don't see any magic in Rust's borrowing beyond what you would get with using shared_ptr, weak_ptr and move semantics in C++11. Yeah there is a certain class of errors that the Rust compiler will check that will still give you a segfault in C++. But it doesn't get around the programmer still needing to have a firm understanding of RAII and the difference between the stack and heap in order to be effec…

The more strict static checking in Rust means that the compiler can actually be a teaching tool for concepts like RAII and the heap/stack difference: it flags and explains places where the programmer is doing that doesn't make sense in those settings. A lot of effort has been put into the compiler diagnostics to make this compiler-is-a-teacher concept a reality.

Re: Rust is Software's Salvation

#160

Earlier quoted context omitted.

If we were betting money, I'd put mine on Golang over Rust just because of the piles of money and effort Google keeps pouring into it. Rust is a little cooler, but I just don't see Mozilla having enough resources to keep-up the momentum long-term.

Go's not been receiving any piles of money from Google. Compare Go's API documentation to Rust's API documentation. Where's the `cargo` and `rustup` equivalent for Go? Compare the number of Go packages to the number of Rust packages. Seems Go's not doing so great despite being stable for much longer. > I just don't see Mozilla having enough resources to keep-up the momentum long-term. Did you forget about Samsung? Mo…

When was the last time you heard of Samsung being involved with Rust as a company? I'm fairly sure that is no longer a thing.
Post reply on HN