Rock YouTube channel with real views, likes and subscribers
Get Free YouTube Subscribers, Views and Likes

A Simpler Way to See Results

Follow
Logan Smith

Result is Rust's error handling type that is often discussed in the same (or similar) breath as Option, but it feels... scarier. But in this video, I'll argue that that relationship with Option is a useful piece to focus on; they are isomorphic in certain circumstances, and even when they're not, you can think of them as coexisting on a continuum. Then we'll talk about the dreaded/beloved question mark, FromIterator/collect, and some Error stuff.

Special guest appearances from anyhow, thiserror, derive_more, and boxed Error trait objects; Haskell donotation, applicative functors, and the first official time I've ever said 'monad' on this channel; and more.

Links I promised:
Study of std::io::Error https://matklad.github.io/2020/10/15/...
thiserror https://docs.rs/thiserror/latest/this...

Other stuff:
Result module docs https://doc.rustlang.org/std/result/
Result chapter in the book https://doc.rustlang.org/book/ch090...
! https://doc.rustlang.org/std/primiti...
Haskell do notation https://en.wikibooks.org/wiki/Haskell...
Sum type https://en.wikipedia.org/wiki/Tagged_...
Isomorphism https://en.wikipedia.org/wiki/Isomorp...
Bottom type https://en.wikipedia.org/wiki/Bottom_...

I use the amazing Manim library for animating these videos, and I edit them with Blender and Audacity.
https://www.manim.community/
https://www.blender.org/
https://www.audacityteam.org/

posted by electryas