3 ms·
Oh yeah, that's likely it. Thanks! It it safe to just put a noop in there? What's From-ness? Is QuestionError defined in std? Where do I read more? EDIT:
by wyldfire 8y ago
Oh yeah, that's likely it. Thanks!
It it safe to just put a noop in there? What's From-ness? Is QuestionError defined in std? Where do I read more?
EDIT: oh I see, I didn't read carefully. I just need to provide a conversion. Your example is very clear.
- ds206 8y agoIt's how you explicitly cast from one type to another. To use the ? operator with a custom error type, it needs to be converted to the std error type.
- steveklabnik 8y agoIt needs to be converted to whatever error type the function returns. That can be anything.