fixed maximum radix value from 32 to 36
This commit is contained in:
parent
ca1e27a84e
commit
6c644d1256
1 changed files with 1 additions and 1 deletions
|
|
@ -100,7 +100,7 @@ impl std::str::FromStr for Base {
|
||||||
.map_err(|_| format!("'{}' is not a valid base", s))?,
|
.map_err(|_| format!("'{}' is not a valid base", s))?,
|
||||||
};
|
};
|
||||||
|
|
||||||
if (2..=32).contains(&radix) {
|
if (2..=36).contains(&radix) {
|
||||||
Ok(Base(radix))
|
Ok(Base(radix))
|
||||||
} else {
|
} else {
|
||||||
Err(format!("base must be between 2 and 36, got {}", radix))
|
Err(format!("base must be between 2 and 36, got {}", radix))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue