From 0c628db882f466ee0afa549fb09ba19e69b194dc Mon Sep 17 00:00:00 2001 From: Folkert Date: Sat, 31 Jul 2021 12:17:58 +0200 Subject: [PATCH] clippy --- compiler/types/src/pretty_print.rs | 6 +++--- compiler/types/src/subs.rs | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/compiler/types/src/pretty_print.rs b/compiler/types/src/pretty_print.rs index 9f0d9c6b87..6805c80088 100644 --- a/compiler/types/src/pretty_print.rs +++ b/compiler/types/src/pretty_print.rs @@ -500,7 +500,7 @@ fn write_flat_type(env: &Env, flat_type: &FlatType, subs: &Subs, buf: &mut Strin // // e.g. the "*" at the end of `{ x: I64 }*` // or the "r" at the end of `{ x: I64 }r` - write_content(env, &content, subs, buf, parens) + write_content(env, content, subs, buf, parens) } } @@ -519,7 +519,7 @@ fn write_flat_type(env: &Env, flat_type: &FlatType, subs: &Subs, buf: &mut Strin // // e.g. the "*" at the end of `{ x: I64 }*` // or the "r" at the end of `{ x: I64 }r` - write_content(env, &content, subs, buf, parens) + write_content(env, content, subs, buf, parens) } } @@ -536,7 +536,7 @@ fn write_flat_type(env: &Env, flat_type: &FlatType, subs: &Subs, buf: &mut Strin // // e.g. the "*" at the end of `{ x: I64 }*` // or the "r" at the end of `{ x: I64 }r` - write_content(env, &content, subs, buf, parens) + write_content(env, content, subs, buf, parens) } buf.push_str(" as "); diff --git a/compiler/types/src/subs.rs b/compiler/types/src/subs.rs index ee4b024a93..0baa5252e7 100644 --- a/compiler/types/src/subs.rs +++ b/compiler/types/src/subs.rs @@ -666,7 +666,7 @@ fn occurs( Func(arg_vars, closure_var, ret_var) => { let it = once(ret_var) .chain(once(closure_var)) - .chain(arg_vars.into_iter()); + .chain(arg_vars.iter()); short_circuit(subs, root_var, &new_seen, it) } Record(vars_by_field, ext_var) => {