3 ms·
It's very difficult, but important thing, to express abstract things in a correct, yet still understandable way, so "kudos" for trying :) You make a good point
by ceceron 6y ago
It's very difficult, but important thing, to express abstract things in a correct, yet still understandable way, so "kudos" for trying :)
You make a good point, however:
1) > And that designing an entire language around this idea to ensure "safety", especially without it being "proven" in a smaller language, is/was very risky and dodgy
It's not exactly true that ownership models weren't "proven" in different languages. Objective-C comes from the top of my head; the main memory management technique there was reference counting (with the memory pool/manual management fallback). And yes, the non-linearity of some structures was a pain in the ass, one had to be careful to not create a "strong reference loop", but... in the end it worked quite well :) The difference is that in Obj-C one had to do it manually/in runtime, Rust checks it automatically/during compilation.
2) quoting your article "Ownership semantics [...] cannot be used to express non-linear problems".
This is a very strong claim. What does it mean for the problem to be non-linear? I would say, that linearity (in programming) may be ascribed to a model of the problem, not the problem itself, i.e. Traveling Salesman Problem is a problem involving a non-linear structure and still the best known solvers (e.g. Concorde) use linear models to solve it.
It is true that ownership semantics has to be bypassed in the non-linear model, but the question stays whether the given problem really requires one.