this post was submitted on 19 Mar 2026
18 points (90.9% liked)
Rust
7875 readers
42 users here now
Welcome to the Rust community! This is a place to discuss about the Rust programming language.
Wormhole
Credits
- The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
To Panic or not to Panic Thank you for your pointer. I just remember this from the docs. So basically, the general rule is only to use panic when something bad really happened, and my program cannot continue right? otherwise always return the error?
I'll rethink the use of panic in my code
would this section suffice? https://doc.rust-lang.org/book/ch09-00-error-handling.html