We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c121c03 commit 084bca2Copy full SHA for 084bca2
1 file changed
src/args/depth.rs
@@ -34,21 +34,20 @@ pub enum FromStrError {
34
35
impl FromStr for Depth {
36
type Err = FromStrError;
37
- fn from_str(source: &str) -> Result<Self, Self::Err> {
38
- let source = source.trim();
39
- if source == INFINITE {
+ fn from_str(text: &str) -> Result<Self, Self::Err> {
+ let text = text.trim();
+ if text == INFINITE {
40
return Ok(Depth::Infinite);
41
}
42
- source
43
- .parse()
+ text.parse()
44
.map_err(FromStrError::InvalidSyntax)
45
.map(Depth::Finite)
46
47
48
49
impl TryFrom<u64> for Depth {
50
type Error = TryFromIntError;
51
- fn try_from(source: u64) -> Result<Self, Self::Error> {
52
- source.try_into().map(Depth::Finite)
+ fn try_from(value: u64) -> Result<Self, Self::Error> {
+ value.try_into().map(Depth::Finite)
53
54
0 commit comments