tjpalmer•

Not OP, but in case it's helpful to anyone, I made this video to demonstrate parallel requests using async/await with the new Rust features.

35
mmstick•

Although it's notably useful for executing many tasks concurrently from the same thread, using the idle time between I/O to carry out other tasks, in order to keep your thread saturated with load.

Great for reading and writing files, performing network requests, and waiting on external commands to complete without needing to use threads.

7
jokubolakis•

Are a lot of these additional nifty features bundled up in cargo crates?

6
cybergaiato•

Futures are built into the standard library, the executors of the futures are not. So you need crates because different tasks need different executors (and things are still being iterated over, maybe one day it's stable enough to go die in the std lib).

7
tjpalmer•

All my dependencies are listed in my Cargo.toml: https://github.com/tjpalmer/async-demo/blob/master/Cargo.toml

On Ubuntu, for reqwest's dependencies, I also had to apt install pkg-config and libssl-dev beyond what I previously had installed before working on this.

3
contantofaz•

I'm currently writing another little tool to practice Rust and get something in return. I've been learning it for the past few weeks and it has been OK so far. More so because I'm Windows 10 and Windows isn't known for enjoying the latest and greatest of some programming tools that tend to target Linux/*nix instead. If you are on Windows like me, you should give Rust a try.

30
L3tum•

I've been doing the same (just not a tool but an OS) and honestly while the ideas of it are very cool (being able to replace features of the stdlib, ownership etc), it's very awkward to type for me. Maybe because I'm a C#/C++/PHP guy but it just doesn't have a flow, and not being 100% familiar with the ownership model often results in me trying frantically to do something that's very very basic in other languages (like adding a reference to an element to a static list).

I do appreciate the language and the differences it has, but I dislike the syntax and some of it is very special and hard to get into

11
shadow31•

As somebody who learned C# then F# and then Rust, I found Rust to be a pretty nice combination of ML style languages and C style languages. Once I got over that initial hump, I didn't have much issue getting into the flow with Rust and sometimes find it has spoiled C# for me because of how much ceremony is required to do basic things like create a data object.

17
hyperum•

If you’re familiar with modern C++, it’s pretty similar to RAII + std::move and rvalue references. As someone who programmed for 4 years in C++ before trying out Rust, I also found the syntax to be comfortably familiar and welcoming as compared to my experience with learning other more common languages, whether FP or multi-paradigm.

2
trin456•

We really needed a language like Rust 20 years ago

I used to argue that garbage collectors are useless and too slow, and Java are too memory heavy to run on my PC with 64mb ram.

But now computers are much faster, and gc languages are much easier to use

2
zickige_zicke•

Give linux subsystem on windows a try

3
stack-compression•

It's a rust release thread! Sort by controversial and wait for shevy-ruby to weigh in on this.

10
insanitybit•
6
carbonkid619•

Hmm, that comment actually seems fairly constructive, compared to what shevy-ruby usually does.

10
Exponentialp32•

Hi everyone, if any of you are gonna be in London on the 3rd of December the Rust London User group is going to be having a special **The Async-Await is Over Christmas Party** at the TrueLayer offices. It's going to be a casual social, with a special Async-Await Q&A Panel. There will be free food and drink as well. https://www.meetup.com/Rust-London-User-Group/ This is the link to the general user group page, the details of the actual Christmas party will be up in a couple of weeks after I've finalised the details of the Q&A Panel.

1
infablhypop•

Now it seems like there should be a similar special keyword for defining functions that return results without extra annotations and ;Ok(()).

0
reedef•

like a monad keyword?

1