This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +3
-5
lines changed Expand file tree Collapse file tree 4 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -233,7 +233,6 @@ impl InferenceContext<'_> {
233
233
} ;
234
234
let mut expectations_iter = expectations
235
235
. iter ( )
236
- . cloned ( )
237
236
. map ( |a| a. assert_ty_ref ( Interner ) . clone ( ) )
238
237
. chain ( repeat_with ( || self . table . new_type_var ( ) ) ) ;
239
238
Original file line number Diff line number Diff line change @@ -3673,7 +3673,6 @@ impl Closure {
3673
3673
let ( captures, _) = infer. closure_info ( & self . id ) ;
3674
3674
captures
3675
3675
. iter ( )
3676
- . cloned ( )
3677
3676
. map ( |capture| Type {
3678
3677
env : db. trait_environment_for_body ( owner) ,
3679
3678
ty : capture. ty ( & self . subst ) ,
Original file line number Diff line number Diff line change @@ -79,7 +79,7 @@ pub(crate) fn goto_definition(
79
79
return Some ( vec ! [ x] ) ;
80
80
}
81
81
82
- if let Some ( x) = try_lookup_macro_def_in_macro_use ( sema, token. clone ( ) ) {
82
+ if let Some ( x) = try_lookup_macro_def_in_macro_use ( sema, token) {
83
83
return Some ( vec ! [ x] ) ;
84
84
}
85
85
}
Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ impl FieldOrTupleIdx {
69
69
. as_str ( )
70
70
. map ( |s| s. to_owned ( ) )
71
71
. unwrap_or_else ( || format ! ( ".{}" , f. name( db) . as_tuple_index( ) . unwrap( ) ) ) ,
72
- FieldOrTupleIdx :: TupleIdx ( i) => format ! ( ".{i}" ) . to_owned ( ) ,
72
+ FieldOrTupleIdx :: TupleIdx ( i) => format ! ( ".{i}" ) ,
73
73
}
74
74
}
75
75
}
@@ -203,7 +203,7 @@ pub(crate) fn view_memory_layout(
203
203
204
204
let mut nodes = vec ! [ MemoryLayoutNode {
205
205
item_name,
206
- typename: typename . clone ( ) ,
206
+ typename,
207
207
size: layout. size( ) ,
208
208
offset: 0 ,
209
209
alignment: layout. align( ) ,
You can’t perform that action at this time.
0 commit comments