2 ms·
For me the best thing about Rust is that I can create beautiful APIs that are hard to misuse. With ownership rules I can enforce logic of how my API is suppose
by pornel 10y ago
For me the best thing about Rust is that I can create beautiful APIs that are hard to misuse.
With ownership rules I can enforce logic of how my API is supposed to be used, e.g. "you can call this method only once", "you can use that object only until you call destroy() on the parent" can be enforced at compile time. Same with levels of thread-safety of my code. Users of my libraries don't need to RTFM to use them correctly.