> In that case, I would suggest coming up with your own pattern. Perhaps an unwrap() with a FIXME comment. Or a expect("FIXME").
That's the sort of thing that's a lot more effective if everyone does the same thing. So it's worth trying to standardise across the community.
Re:Using unwrap() in Rust is okay
by burntsushi on Tuesday August 09, 2022 @09:09AM
(#32397292)
That's a non-sequitur. Just because it would be more effective doesn't mean it's actually worth trying to standardize. I see no accounting of trade offs. I see no accounting for how common the pattern is in practice. I see no accounting for the confusion that will result when there are two methods that behave identically, are named different and should be used in two very subtly different and nuanced ways.
I'd prefer if you just leave me alone to be honest.
I don't find myself in that position too frequently. Certainly not enough to warrant two identical but differently named functions.
In that case, I would suggest coming up with your own pattern. Perhaps an unwrap() with a FIXME comment. Or a expect("FIXME").