Live data from Hacker News

Rust 1.24

blog.rust-lang.org

211–215 of 215 posts

Re: Rust 1.24

#211

Earlier quoted context omitted.

My criticisms are meant to point out areas for actual improvement. Try to be scientific. If you've got a conjecture, test it and see if it holds water. One excuse was that C++ is only faster because people build C++ projects with separate compilation units. Well, you can compile a project in C++ with a single compilation unit, and it's not horribly slow. Now you need a new conjecture. The type system is comparable to…

Borrow checking is a lot more involved than const correctness. It's not even in the same league. Const correctness just adds a few more types, whereas borrow checking involves generating sets of constraints and solving them with a constraint solver, something C++ doesn't really have to do at all. The type system of Rust goes significantly beyond that of Standard ML, because of traits/typeclasses among many other feat…

I'm not going to dive into your points about constraint solvers, type classes, or "monomorphization". Unless those things take more than a few percent of the compile time, they're just more red herrings.

> Incremental compilation is a way of addressing the compile time and memory usage issues. It's just not the way you seem to want them to be fixed. Nobody did incremental compilation for fun.

I'm well aware that my opinion doesn't matter, but I doubt incremental compilation will make any real strides towards making things as good as they could be. It sounds like the real problem is here:

> If I had to guess what the most important issue is, it's that idiomatic Rust generates a lot more LLVM IR than idiomatic C++ does

I suspect every single feature in idiomatic Rust has a one-to-one translation to some bit of C++ that isn't too horrible. You can do lambdas, iterators, generators, or whatever else it takes to do Rust style for loops and closures in C++, and it won't choke the compiler. So while I don't doubt rustc is generating a lot more IR, I doubt it needs to.

Maybe the MIR optimization pass will move in that direction.

Re: Rust 1.24

#212
post #187
post #185

Earlier quoted context omitted.

RLS works just fine on my Linux box, error detection and completion and formatting. Debugging is so so, not very good. But on my Mac box, it's always crashing.

For me it's a) crashing quite often on Windows and Linux and b) doesn't really autocomplete anything beyond really simple cases where I don't need it like "Vec:: ::" will give me new. But on most things it's just really awful. Error detection, at least in VSCode is only displayed after compiling, that might be the plugin though.

I have to make a correction, the Rust (rls) plugin now works much better. I updated my rust distribution.

Re: Rust 1.24

#213
post #73

Earlier quoted context omitted.

I tried Actix a while back and it was very intimidating compared to some other frameworks. I'd like to jump back into it at some point, but right now for my prototype I got lazy and went with Rocket.rs. Any suggestions of Opensource projects that use Actix?

you should check it again :) actix-web now has user guide https://actix.github.io/actix-web/guide/ here is irc bot (wip) https://github.com/DoumanAsh/roseline.rs

Thanks fafhrd!

Re: Rust 1.24

#214
I recently rewrote a few small c scripts in Rust, (mostly to try the language features), the experience was really good. I don't think I will ever start a new project in C again.

Re: Rust 1.24

#215
post #147
post #137

Earlier quoted context omitted.

> I was delighted to see Sum-Product types in Rust when I played with it. They go a long way to cleanly model the problem domain. Umm yeah, they've been a part of every ML-family language since the '70s, OCaml, Haskell and Rust included.

(FullyFunctional seems to understand this, as far as I can tell)

I do, but I wasn't aware that Rust was considered in the ML family (ML as Meta Language, like SML/NJ). I'm somewhat skeptical of that.

What I see from Rust is a lot of the really great things from functional languages (esp. strong typing) and beyond, but applying them to a language aiming as low as C. That's certainly interesting.

Post reply on HN