[INFO] updating cached repository lyneca/pizza [INFO] running `"git" "fetch" "--all"` [INFO] [stdout] Fetching origin [INFO] [stderr] From git://github.com/lyneca/pizza [INFO] [stderr] * branch HEAD -> FETCH_HEAD [INFO] running `"git" "clone" "work/cache/sources/gh/lyneca/pizza" "work/ex/clippy-test-run/sources/stable/gh/lyneca/pizza"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable/gh/lyneca/pizza'... [INFO] [stderr] done. [INFO] running `"git" "clone" "work/cache/sources/gh/lyneca/pizza" "work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/lyneca/pizza"` [INFO] [stderr] Cloning into 'work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/lyneca/pizza'... [INFO] [stderr] done. [INFO] running `"git" "rev-parse" "HEAD"` [INFO] [stdout] 6fa11dd2875eedc4155fa60e10dd64115170f564 [INFO] sha for GitHub repo lyneca/pizza: 6fa11dd2875eedc4155fa60e10dd64115170f564 [INFO] validating manifest of lyneca/pizza on toolchain stable [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "read-manifest" "--manifest-path" "Cargo.toml"` [INFO] validating manifest of lyneca/pizza on toolchain stable+rustflags=-Dclippy::into_iter_on_array [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "read-manifest" "--manifest-path" "Cargo.toml"` [INFO] started frobbing lyneca/pizza [INFO] finished frobbing lyneca/pizza [INFO] frobbed toml for lyneca/pizza written to work/ex/clippy-test-run/sources/stable/gh/lyneca/pizza/Cargo.toml [INFO] started frobbing lyneca/pizza [INFO] finished frobbing lyneca/pizza [INFO] frobbed toml for lyneca/pizza written to work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/lyneca/pizza/Cargo.toml [INFO] crate lyneca/pizza has a lockfile. skipping [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "fetch" "--locked" "--manifest-path" "Cargo.toml"` [INFO] running `"/mnt/big/crater/work/local/cargo-home/bin/cargo" "+stable" "fetch" "--locked" "--manifest-path" "Cargo.toml"` [INFO] linting lyneca/pizza against stable+rustflags=-Dclippy::into_iter_on_array for clippy-test-run [INFO] running `"docker" "create" "-v" "/mnt/big/crater/work/local/target-dirs/clippy-test-run/worker-7/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array:/opt/crater/target:rw,Z" "-v" "/mnt/big/crater/work/ex/clippy-test-run/sources/stable+rustflags=-Dclippy%3A%3Ainto_iter_on_array/gh/lyneca/pizza:/opt/crater/workdir:ro,Z" "-v" "/mnt/big/crater/work/local/cargo-home:/opt/crater/cargo-home:ro,Z" "-v" "/mnt/big/crater/work/local/rustup-home:/opt/crater/rustup-home:ro,Z" "-e" "USER_ID=1000" "-e" "SOURCE_DIR=/opt/crater/workdir" "-e" "MAP_USER_ID=1000" "-e" "CARGO_TARGET_DIR=/opt/crater/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid -Dclippy::into_iter_on_array" "-e" "CARGO_HOME=/opt/crater/cargo-home" "-e" "RUSTUP_HOME=/opt/crater/rustup-home" "-w" "/opt/crater/workdir" "-m" "1536M" "--network" "none" "rustops/crates-build-env" "/opt/crater/cargo-home/bin/cargo" "+stable" "clippy" "--frozen" "--all" "--all-targets"` [INFO] [stdout] f11a0439a35ea7ceb417f5aaf91a989cd63691140cc7b7cb42b5ff02ae3d2ab0 [INFO] running `"docker" "start" "-a" "f11a0439a35ea7ceb417f5aaf91a989cd63691140cc7b7cb42b5ff02ae3d2ab0"` [INFO] [stderr] Checking pizza v0.1.0 (/opt/crater/workdir) [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | write!(f, "Order:\n").unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::write_with_newline)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:26:9 [INFO] [stderr] | [INFO] [stderr] 26 | write!(f, " - Double Bacon Cheeseburger: {}\n", self.dbc).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:27:9 [INFO] [stderr] | [INFO] [stderr] 27 | write!(f, " - Pepperoni: {}\n", self.pep).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:28:9 [INFO] [stderr] | [INFO] [stderr] 28 | write!(f, " - Supreme: {}\n", self.sup).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:29:9 [INFO] [stderr] | [INFO] [stderr] 29 | write!(f, " - Beef and Onion: {}\n", self.bao).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:30:9 [INFO] [stderr] | [INFO] [stderr] 30 | write!(f, " - Hawaiian: {}\n", self.haw).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:31:9 [INFO] [stderr] | [INFO] [stderr] 31 | write!(f, " - Cheese: {}\n", self.che).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:32:9 [INFO] [stderr] | [INFO] [stderr] 32 | write!(f, " - Margherita: {}\n", self.mar).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:33:9 [INFO] [stderr] | [INFO] [stderr] 33 | write!(f, " - BBQ Pork and Onion: {}\n", self.bpo).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:34:9 [INFO] [stderr] | [INFO] [stderr] 34 | write!(f, " - BBQ Meatlovers: {}\n", self.bml).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:35:9 [INFO] [stderr] | [INFO] [stderr] 35 | write!(f, " - Eight Meats: {}\n", self.eme).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:36:9 [INFO] [stderr] | [INFO] [stderr] 36 | write!(f, " - Vegetarian: {}\n", self.veg).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:37:9 [INFO] [stderr] | [INFO] [stderr] 37 | write!(f, " - Garlic Bread: {}\n", self.gar).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:38:9 [INFO] [stderr] | [INFO] [stderr] 38 | write!(f, " - Drinks: {}\n", self.dri) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:25:9 [INFO] [stderr] | [INFO] [stderr] 25 | write!(f, "Order:\n").unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::write_with_newline)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:26:9 [INFO] [stderr] | [INFO] [stderr] 26 | write!(f, " - Double Bacon Cheeseburger: {}\n", self.dbc).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:27:9 [INFO] [stderr] | [INFO] [stderr] 27 | write!(f, " - Pepperoni: {}\n", self.pep).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:28:9 [INFO] [stderr] | [INFO] [stderr] 28 | write!(f, " - Supreme: {}\n", self.sup).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:29:9 [INFO] [stderr] | [INFO] [stderr] 29 | write!(f, " - Beef and Onion: {}\n", self.bao).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:30:9 [INFO] [stderr] | [INFO] [stderr] 30 | write!(f, " - Hawaiian: {}\n", self.haw).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:31:9 [INFO] [stderr] | [INFO] [stderr] 31 | write!(f, " - Cheese: {}\n", self.che).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:32:9 [INFO] [stderr] | [INFO] [stderr] 32 | write!(f, " - Margherita: {}\n", self.mar).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:33:9 [INFO] [stderr] | [INFO] [stderr] 33 | write!(f, " - BBQ Pork and Onion: {}\n", self.bpo).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:34:9 [INFO] [stderr] | [INFO] [stderr] 34 | write!(f, " - BBQ Meatlovers: {}\n", self.bml).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:35:9 [INFO] [stderr] | [INFO] [stderr] 35 | write!(f, " - Eight Meats: {}\n", self.eme).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:36:9 [INFO] [stderr] | [INFO] [stderr] 36 | write!(f, " - Vegetarian: {}\n", self.veg).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:37:9 [INFO] [stderr] | [INFO] [stderr] 37 | write!(f, " - Garlic Bread: {}\n", self.gar).unwrap(); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: using `write!()` with a format string that ends in a single newline, consider using `writeln!()` instead [INFO] [stderr] --> src/main.rs:38:9 [INFO] [stderr] | [INFO] [stderr] 38 | write!(f, " - Drinks: {}\n", self.dri) [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#write_with_newline [INFO] [stderr] [INFO] [stderr] warning: Unnecessary `>= y + 1` or `x - 1 >=` [INFO] [stderr] --> src/main.rs:105:11 [INFO] [stderr] | [INFO] [stderr] 105 | while order.sum() + 1 <= people + veg { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::int_plus_one)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#int_plus_one [INFO] [stderr] help: change `>= y + 1` to `> y` as shown [INFO] [stderr] | [INFO] [stderr] 105 | while order.sum() < people + veg { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: Unnecessary `>= y + 1` or `x - 1 >=` [INFO] [stderr] --> src/main.rs:105:11 [INFO] [stderr] | [INFO] [stderr] 105 | while order.sum() + 1 <= people + veg { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::int_plus_one)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#int_plus_one [INFO] [stderr] help: change `>= y + 1` to `> y` as shown [INFO] [stderr] | [INFO] [stderr] 105 | while order.sum() < people + veg { [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:69:17 [INFO] [stderr] | [INFO] [stderr] 69 | let scale = people as f32 / 15.0; [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::cast_lossless)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:73:21 [INFO] [stderr] | [INFO] [stderr] 73 | let veg_scale = veg as f32 / 4.0; [INFO] [stderr] | ^^^^^^^^^^ help: try: `f32::from(veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:75:22 [INFO] [stderr] | [INFO] [stderr] 75 | let total: f32 = (people + veg) as f32; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `f32::from(people + veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:121:6 [INFO] [stderr] | [INFO] [stderr] 121 | (people as f32 * (2.0 / 3.0)).floor() as u16 [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:126:6 [INFO] [stderr] | [INFO] [stderr] 126 | (people as f32 * (2.0 / 3.0)).ceil() as u16 [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:149:58 [INFO] [stderr] | [INFO] [stderr] 149 | println!("Total: {}, {:.2} per person", order.sum(), order.sum() as f32 / (num_people + num_veg) as f32); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^ help: try: `f32::from(order.sum())` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:149:79 [INFO] [stderr] | [INFO] [stderr] 149 | println!("Total: {}, {:.2} per person", order.sum(), order.sum() as f32 / (num_people + num_veg) as f32); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `f32::from(num_people + num_veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:69:17 [INFO] [stderr] | [INFO] [stderr] 69 | let scale = people as f32 / 15.0; [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = note: #[warn(clippy::cast_lossless)] on by default [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:73:21 [INFO] [stderr] | [INFO] [stderr] 73 | let veg_scale = veg as f32 / 4.0; [INFO] [stderr] | ^^^^^^^^^^ help: try: `f32::from(veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:75:22 [INFO] [stderr] | [INFO] [stderr] 75 | let total: f32 = (people + veg) as f32; [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^ help: try: `f32::from(people + veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:121:6 [INFO] [stderr] | [INFO] [stderr] 121 | (people as f32 * (2.0 / 3.0)).floor() as u16 [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:126:6 [INFO] [stderr] | [INFO] [stderr] 126 | (people as f32 * (2.0 / 3.0)).ceil() as u16 [INFO] [stderr] | ^^^^^^^^^^^^^ help: try: `f32::from(people)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:149:58 [INFO] [stderr] | [INFO] [stderr] 149 | println!("Total: {}, {:.2} per person", order.sum(), order.sum() as f32 / (num_people + num_veg) as f32); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^ help: try: `f32::from(order.sum())` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] warning: casting u16 to f32 may become silently lossy if types change [INFO] [stderr] --> src/main.rs:149:79 [INFO] [stderr] | [INFO] [stderr] 149 | println!("Total: {}, {:.2} per person", order.sum(), order.sum() as f32 / (num_people + num_veg) as f32); [INFO] [stderr] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `f32::from(num_people + num_veg)` [INFO] [stderr] | [INFO] [stderr] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_lossless [INFO] [stderr] [INFO] [stderr] Finished dev [unoptimized + debuginfo] target(s) in 0.82s [INFO] running `"docker" "inspect" "f11a0439a35ea7ceb417f5aaf91a989cd63691140cc7b7cb42b5ff02ae3d2ab0"` [INFO] running `"docker" "rm" "-f" "f11a0439a35ea7ceb417f5aaf91a989cd63691140cc7b7cb42b5ff02ae3d2ab0"` [INFO] [stdout] f11a0439a35ea7ceb417f5aaf91a989cd63691140cc7b7cb42b5ff02ae3d2ab0