Time to try_
again?
#Time to try_
again?
TheThe closure that starts here contains several .unwrap()
because some locks you do might not yield anything.
Compiler Warnings
#Compiler Warnings TheThe Rust compiler is your friend! When I compile your code on my machine, I get several warnings.
#Time to try_
again?
The closure that starts here contains several .unwrap()
because some locks you do might not yield anything.
#Compiler Warnings The Rust compiler is your friend! When I compile your code on my machine, I get several warnings.
Time to try_
again?
The closure that starts here contains several .unwrap()
because some locks you do might not yield anything.
Compiler Warnings
The Rust compiler is your friend! When I compile your code on my machine, I get several warnings.
Also keep in mind that there are other places where .unwrap()
and .expect()
are used in your application. Adding to your error enum may be necessary, but in other cases like the one above it may be as simple as rethinking the problem you were trying to solve and finding a new way to express it using the tools Rust gives you. Only add to your error enum when you're sure you've found an edge case that's probably outside of the scope of your program.
Also keep in mind that there are other places where .unwrap()
and .expect()
are used in your application. Adding to your error enum may be necessary, but in other cases like the one above it may be as simple as rethinking the problem you were trying to solve and finding a new way to express it using the tools Rust gives you. Only add to your error enum when you're sure you've found an edge case that's probably outside of the scope of your program.