summaryrefslogtreecommitdiffstats
path: root/examples/pure/game_of_life
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-07-09 18:42:41 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-07-09 18:43:05 +0200
commit2065a40f642589134142a740ff4198deaa4c378b (patch)
tree00477d6d7cb571332062535557151d5b031d8925 /examples/pure/game_of_life
parentd53cc5498b92fb6b573867f5ccb5f8ac93f6be79 (diff)
downloadiced-2065a40f642589134142a740ff4198deaa4c378b.tar.gz
iced-2065a40f642589134142a740ff4198deaa4c378b.tar.bz2
iced-2065a40f642589134142a740ff4198deaa4c378b.zip
Fix `clippy` lints for all crates and features
... and check those in CI as well!
Diffstat (limited to 'examples/pure/game_of_life')
-rw-r--r--examples/pure/game_of_life/src/main.rs2
-rw-r--r--examples/pure/game_of_life/src/preset.rs10
2 files changed, 6 insertions, 6 deletions
diff --git a/examples/pure/game_of_life/src/main.rs b/examples/pure/game_of_life/src/main.rs
index 851fbd47..cf6560d6 100644
--- a/examples/pure/game_of_life/src/main.rs
+++ b/examples/pure/game_of_life/src/main.rs
@@ -350,7 +350,7 @@ mod grid {
}
}
- pub fn view<'a>(&'a self) -> Element<'a, Message> {
+ pub fn view(&self) -> Element<Message> {
Canvas::new(self)
.width(Length::Fill)
.height(Length::Fill)
diff --git a/examples/pure/game_of_life/src/preset.rs b/examples/pure/game_of_life/src/preset.rs
index 05157b6a..964b9120 100644
--- a/examples/pure/game_of_life/src/preset.rs
+++ b/examples/pure/game_of_life/src/preset.rs
@@ -1,7 +1,7 @@
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum Preset {
Custom,
- XKCD,
+ Xkcd,
Glider,
SmallExploder,
Exploder,
@@ -14,7 +14,7 @@ pub enum Preset {
pub static ALL: &[Preset] = &[
Preset::Custom,
- Preset::XKCD,
+ Preset::Xkcd,
Preset::Glider,
Preset::SmallExploder,
Preset::Exploder,
@@ -30,7 +30,7 @@ impl Preset {
#[rustfmt::skip]
let cells = match self {
Preset::Custom => vec![],
- Preset::XKCD => vec![
+ Preset::Xkcd => vec![
" xxx ",
" x x ",
" x x ",
@@ -116,7 +116,7 @@ impl Preset {
impl Default for Preset {
fn default() -> Preset {
- Preset::XKCD
+ Preset::Xkcd
}
}
@@ -127,7 +127,7 @@ impl std::fmt::Display for Preset {
"{}",
match self {
Preset::Custom => "Custom",
- Preset::XKCD => "xkcd #2293",
+ Preset::Xkcd => "xkcd #2293",
Preset::Glider => "Glider",
Preset::SmallExploder => "Small Exploder",
Preset::Exploder => "Exploder",