Originally posted by TheMightyBuzzard
View Post
Every new graduate is familiar with async/await stuff because they learn javascript, generics/interfaces should be familiar from Java, C#, or Typescript, and learning that adding a ? gives you error handling is trivial. Box is simpler than learning new or malloc + memcopy.
That code snippet has a bunch of unfamiliar looking syntax in it for a C developer, which I think is the point. But anyone who's spent a week learning Rust could glance at it and instantly understand it with no problems, because it's just simple syntax stuff. No complex logic. A corresponding sample in C would be far harder to parse through because it would have so much boilerplate error handling/setup/etc. obscuring the real code.
I will say being able to properly design a good Rust library API is more complex than one in C because you need to take into account a lot more about how it will be getting used, whereas in another language you can just do anything you want and then document it all. But that's not something a new graduate should be doing anyway. Using it and understanding what an existing method does is simple.
Comment