mirror of
https://github.com/RGBCube/dix
synced 2025-07-28 12:17:45 +00:00
fix: don't use nightly features
This commit is contained in:
parent
baaf63fdf2
commit
416dc0c455
1 changed files with 15 additions and 12 deletions
11
src/main.rs
11
src/main.rs
|
@ -185,9 +185,9 @@ fn main() {
|
||||||
|
|
||||||
let mut chars = message.char_indices();
|
let mut chars = message.char_indices();
|
||||||
|
|
||||||
let _ = if let Some((_, first)) = chars.next()
|
let _ = match (chars.next(), chars.next()) {
|
||||||
&& let Some((second_start, second)) = chars.next()
|
(Some((_, first)), Some((second_start, second)))
|
||||||
&& second.is_lowercase()
|
if second.is_lowercase() =>
|
||||||
{
|
{
|
||||||
writeln!(
|
writeln!(
|
||||||
err,
|
err,
|
||||||
|
@ -195,8 +195,11 @@ fn main() {
|
||||||
first_lowercase = first.to_lowercase(),
|
first_lowercase = first.to_lowercase(),
|
||||||
rest = &message[second_start..],
|
rest = &message[second_start..],
|
||||||
)
|
)
|
||||||
} else {
|
},
|
||||||
|
|
||||||
|
_ => {
|
||||||
writeln!(err, "{message}")
|
writeln!(err, "{message}")
|
||||||
|
},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue