Welcome to our comprehensive series on learning Rust, a powerful and efficient programming language. This playlist is designed to guide you from the very basics of Rust to its most advanced features. Whether you're entirely new to programming or an experienced developer looking to add Rust to your skillset, these lessons are structured to provide a clear and progressive learning path. Join us as we explore Rust's unique approach to safety, speed, and concurrency and become proficient in this increasingly popular language. Remember to subscribe and activate notifications so you don't miss the new videos
Curated by: Francesco Ciulla (54 videos)
By the end of this video, you will clearly understand when to use panic! and when to use Result in Rust. We start with a quick recap of the panic! macro and discuss scenarios where it is appropriate to use panic, such as in examples, prototypes, tests, edge cases, and situations where we know more than the Rust compiler. Then, we explore when to use the Result type, focusing on parsing inputs, handling rate-limiting HTTP requests, and creating custom error types. Finally, we summarize the key points. Related videos: https://youtu.be/PCjuO-Bv5FI?si=OEmchCsfcVt67rgV https://youtu.be/mgK5LezkHl8?si=Sjh5Kk6aL-t_lVi_ https://youtu.be/94iSHoKmPmY?si=txvL-tjUf6XIQ8fW https://youtu.be/sd1M_CLXl4I?si=sQqOuwfhAzRVE7HF https://youtu.be/2XwP1U0XL0E?si=uwOwstFSoscsaB9X https://youtu.be/NBFH3BnCIvU?si=slK_5vNhmY3OZXN2 0:00 To panic or not to panic - a quick recap 00:48 When to Use Panic 1:23 Panic for Examples 2:00 panic! for Prototypes 2:56 Panic in Tests 3:24 Panic for Edge Cases 4:00 Panic when we know more than the Rust compiler 5:16 When to use Result in Rust 6:13 Using Result when Parsing Inputs - Handling Parsing Errors 7:10 Use Result to handle rate-limiting HTTP 8:01 Custom Error Types 9:17 Summary - key points ALL THE LINKS HERE: https://francescociulla.com