Skip to content
This repository has been archived by the owner on Sep 24, 2020. It is now read-only.

Avoid fail!s #19

Open
wycats opened this issue Mar 19, 2014 · 1 comment
Open

Avoid fail!s #19

wycats opened this issue Mar 19, 2014 · 1 comment

Comments

@wycats
Copy link
Contributor

wycats commented Mar 19, 2014

Instead of failing, return a result from from_toml, so it can be reported properly. We're using rust-toml in Cargo, and this is a blocker for us 😦

@wycats
Copy link
Contributor Author

wycats commented Mar 19, 2014

FWIW, a pattern I have used (a stopgap until we get better Result support in Rust proper) is to stash an error reason on the decoder struct, and then check for it in the main decoder loop (to skip future decodings that will likely fail).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant