feat: Rewrite try_from_into (#393)

This commit is contained in:
IkaR49
2020-05-16 00:02:57 +03:00
committed by GitHub
parent d6c0a688e6
commit 763aa6e378
3 changed files with 91 additions and 61 deletions

View File

@@ -799,5 +799,6 @@ name = "from_str"
path = "exercises/conversions/from_str.rs"
mode = "test"
hint = """
If you've already solved try_from_into.rs, then this is almost a copy-paste.
Otherwise, go ahead and solve try_from_into.rs first."""
The implementation of FromStr should return an Ok with a Person object,
or an Err with a string if the string is not valid.
This is a some like an `try_from_into` exercise."""