On Tue, Nov 19, 2013 at 4:51 AM, Gaetan <[email protected]> wrote: > In the french presentation for rust 0.8 [1], the author gives the analogy > with C++ semantics > - ~ is a bit like unique_ptr > - @ is an enhanced shared_ptr<T> > - borrowed pointer works like C++ reference > > and I think it was very helpful to better understand them. I don't know if > it is true or now, but this comparison helps a lot understanding the > concepts.You can present them like this, and after, add more precision, and > difference with the C++ counter parts. > > A tutorial to make would be "Rust for C++ programmer" :) > > > [1] http://linuxfr.org/news/presentation-de-rust-0-8 > > ----- > Gaetan
I wrote a reference for C++ programmers on the wiki some time ago. Rust is very easy to approach as if you have a solid grasp of C++11 so I don't think it's an important area to work on. A C++ programmer already has a thorough understanding of the ownership/lifetime concepts in Rust and the trait system will be familiar because C++ has type traits + enable_if and implicit type "concepts" that aren't formalized in the language yet. https://github.com/mozilla/rust/wiki/Rust-for-CXX-programmers _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
