Sign in
fuchsia
/
third_party
/
rust
/
b4cf2cdf870512373a656393f393bce84eb78d80
/
.
/
src
/
tools
/
clippy
/
tests
/
ui
/
single_element_loop.rs
blob: 2c0c03b7211993ee22d5c5022818eec6842cb283 [
file
] [
log
] [
blame
]
// run-rustfix
// Tests from for_loop.rs that don't have suggestions
#[
warn
(
clippy
::
single_element_loop
)]
fn
main
()
{
let
item1
=
2
;
for
item in
&[
item1
]
{
println
!(
"{}"
,
item
);
}
for
item in
[
item1
].
iter
()
{
println
!(
"{:?}"
,
item
);
}
}