Skip to content

Commit aa2559e

Browse files
authored
style: include iter_on_single_items (#798)
1 parent b318350 commit aa2559e

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,6 @@ derive_partial_eq_without_eq = { level = "allow", priority = 1 }
157157
empty_line_after_doc_comments = { level = "allow", priority = 1 }
158158
fallible_impl_from = { level = "allow", priority = 1 }
159159
imprecise_flops = { level = "allow", priority = 1 }
160-
iter_on_single_items = { level = "allow", priority = 1 }
161160
missing_const_for_fn = { level = "allow", priority = 1 }
162161
nonstandard_macro_braces = { level = "allow", priority = 1 }
163162
option_if_let_else = { level = "allow", priority = 1 }

src/math/field.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ mod tests {
236236
for gen in 1..P - 1 {
237237
// every field element != 0 generates the whole field additively
238238
let gen = PrimeField::from(gen as i64);
239-
let mut generated: HashSet<PrimeField<P>> = [gen].into_iter().collect();
239+
let mut generated: HashSet<PrimeField<P>> = std::iter::once(gen).collect();
240240
let mut x = gen;
241241
for _ in 0..P {
242242
x = x + gen;

0 commit comments

Comments
 (0)