Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
tinaun
Jun 9, 2011

                  tell me...

Ghost of Reagan Past posted:

Another question: is there a way to get Cargo to update rustc? They release a new stable every 6 weeks, and so if I want to keep my local updated, how do I do that except uninstall old versions and install the new one (Windows)?

https://github.com/rust-lang-nursery/rustup.rs/ will be the offical way to deal with this soon enough, i haven't tried it on windows yet though, but it has support for it.

Adbot
ADBOT LOVES YOU

tinaun
Jun 9, 2011

                  tell me...
yeah, what you want in this case is split_off, which returns owned strings

tinaun
Jun 9, 2011

                  tell me...
https://dtolnay.github.io/rust-quiz/

I consider myself pretty experienced with rust, and half this quiz broke me. #2 is evil.

tinaun
Jun 9, 2011

                  tell me...
yeah i've been playing around with tide (yet another async web framework) and writing my own futures 0.3 libs for timers and websockets and stuff it's very nice.

tinaun
Jun 9, 2011

                  tell me...
its still early but rust-analyzer is so much better than rls its not even funny

tinaun
Jun 9, 2011

                  tell me...
only .from() .into() .try_from() .try_into() and .from_str() are from traits, the rest are just convention. Every smart pointer type in the std has the .as_[mut_]ptr() / .into_raw() methods, though.

Be extra careful with ownership when working with ffi, it’s easy to accidentally drop smart pointers when they go out of scope before the ffi uses them, and you don’t want to free memory allocated in rust from the c functions and vice versa.

Adbot
ADBOT LOVES YOU

tinaun
Jun 9, 2011

                  tell me...
Serde is not a parsing library.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply