Commit Graph

14 Commits (e6b1ef20496ef2287442c4abef130ae835395a23)

Author SHA1 Message Date
mokou 74f44f55e3 feat(conversions): add hint comments 2 years ago
diannasoriel c2ed98deb3
Merge pull request #781 from tlyu/advanced-errs
feature: advanced errors
3 years ago
Taylor Yu 2dc93cadda fix(from_str, try_from_into): custom error types
Remove the use of trait objects as errors from `from_str` and
`try_from_into`; they seem to have caused a lot of confusion in
practice. (Also, it's considered best practice to use custom error
types instead of boxed errors in library code.) Instead, use custom
error enums, and update hints accordingly. Hints also provide
some guidance about converting errors, which could be covered
more completely in a future advanced errors section.

Also move from_str to directly after the similar exercise `from_into`,
for the sake of familiarity when solving.
3 years ago
Martin HART 86cc85295a fix: Correct small typo in exercises/conversions/from_str.rs 3 years ago
Taylor Yu c3e7b83178 fix: use trait objects for from_str
Use `Box<dyn error::Error>` to allow solutions to use `?` to propagate 
errors.
4 years ago
Jirka Kremser 5f7c89f85d
fix(from_str): Correct typos
typos in the comments
4 years ago
Jean-Francois Chevrette 15e71535f3 fix(from_str): test for error instead of unwrap/should_panic 4 years ago
Sang-Heon Jeon 5a0521e92c feat(from_str) : add test for checking unnecessary trailing value 4 years ago
Étienne Barrié 3144d3ae63 chore: Run rustfmt on exercises 4 years ago
IkaR49 763aa6e378
feat: Rewrite try_from_into (#393) 4 years ago
apatniv 41f989135d Review Comments: Add other test cases 4 years ago
apatniv 19fb1c240c test: Add missing test case for from_str exercise 4 years ago
Abdou Seck fc26b5e151 I AM NOT DONE comment in conversions exercise files 5 years ago
Abdou Seck 0c85dc1193 feat: Add type conversion and parsing exercises 5 years ago