News for hackers. Stuff that matters.
Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by steveklabnik on Tuesday February 21, 2017 @12:51PM (#13697643)
> Exclusive ownership invariably mandates copying for certain use cases.

Hm, why would you not use multiple ownership then, instead?

Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by rbehrends on Tuesday February 21, 2017 @03:56PM (#13699855)
> Hm, why would you not use multiple ownership then, instead?

That's exactly what I want. The problem is that (1) it comes with significant runtime overhead and/or syntactic noise in Rust/C++ (or alternatively, lack of memory safety); and (2), it becomes difficult to write code that works equally well for multiple and exclusive ownership (module APIs often become burdened with implicit or explicit ownership assumptions).

Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by steveklabnik on Tuesday February 21, 2017 @04:13PM (#13700045)
Gotcha. I'm not sure I agree, but I understand :)
Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by rbehrends on Tuesday February 21, 2017 @04:32PM (#13700231)
Well, let me also add that I completely understand that there are use cases for Rust, where a GCed language would be a poor fit. An obvious example is a web browser ( :) ), where the x% memory overhead that comes with a garbage collector is just a price that you may not be able to afford to pay.

In other words, don't read this as "Rust sucks" (I actually rather admire Rust's design), read it as: for my purposes, the practical use cases of Rust are generally too niche to justify the software engineering tradeoffs.

Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by steveklabnik on Tuesday February 21, 2017 @04:57PM (#13700432)
Yeah, I hear you. I think this is fair. And at least some of it comes down to preference, that is, I don't think that the syntactic noise is very much, but others can certainly disagree. The others would mostly be a "nuh uh" since I don't have numbers anyway :)

At the end of the day, Rust can never be great for every single last programmer, and this is entirely okay.

Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by sqeaky on Tuesday February 21, 2017 @02:04PM (#13698481)
I think that is his point, he thinks Rust and C++ cannot do this. But is the default in C++ and well done in Rust.
Re:Nim Language Draws from Best of Python, Rust, Go, and Lisp by rbehrends on Tuesday February 21, 2017 @03:57PM (#13699873)
No, my point is not that it cannot be done (both Rust and C++ are Turing-complete, so "cannot be done" does not make sense for anything that's a computable property), but that it comes with a cost. See my other response for the details.