File tree Expand file tree Collapse file tree 7 files changed +10
-14
lines changed Expand file tree Collapse file tree 7 files changed +10
-14
lines changed Original file line number Diff line number Diff line change @@ -181,7 +181,6 @@ non_canonical_partial_ord_impl = "allow"
181
181
self_named_constructors = " allow"
182
182
too_many_arguments = " allow"
183
183
type_complexity = " allow"
184
- useless_conversion = " allow"
185
184
useless_format = " allow"
186
185
wildcard_in_or_patterns = " allow"
187
186
wrong_self_convention = " allow"
Original file line number Diff line number Diff line change @@ -256,7 +256,7 @@ impl SsrError {
256
256
"## ,
257
257
) ;
258
258
259
- assert_eq ! ( db. body_with_source_map( def. into ( ) ) . 1 . diagnostics( ) , & [ ] ) ;
259
+ assert_eq ! ( db. body_with_source_map( def) . 1 . diagnostics( ) , & [ ] ) ;
260
260
expect ! [ [ r#"
261
261
fn main() {
262
262
_ = $crate::error::SsrError::new(
@@ -309,7 +309,7 @@ fn f() {
309
309
"# ,
310
310
) ;
311
311
312
- let ( _, source_map) = db. body_with_source_map ( def. into ( ) ) ;
312
+ let ( _, source_map) = db. body_with_source_map ( def) ;
313
313
assert_eq ! ( source_map. diagnostics( ) , & [ ] ) ;
314
314
315
315
for ( _, def_map) in body. blocks ( & db) {
Original file line number Diff line number Diff line change @@ -782,7 +782,7 @@ impl<'a> AssocItemCollector<'a> {
782
782
self . diagnostics . push ( DefDiagnostic :: macro_expansion_parse_error (
783
783
self . module_id . local_id ,
784
784
error_call_kind ( ) ,
785
- errors. into ( ) ,
785
+ errors,
786
786
) ) ;
787
787
}
788
788
Original file line number Diff line number Diff line change @@ -475,7 +475,7 @@ impl DefMap {
475
475
let macro_use_prelude = || {
476
476
self . macro_use_prelude . get ( name) . map_or ( PerNs :: none ( ) , |& ( it, _extern_crate) | {
477
477
PerNs :: macros (
478
- it. into ( ) ,
478
+ it,
479
479
Visibility :: Public ,
480
480
// FIXME?
481
481
None , // extern_crate.map(ImportOrExternCrate::ExternCrate),
Original file line number Diff line number Diff line change @@ -131,13 +131,11 @@ impl PerNs {
131
131
. into_iter ( )
132
132
. chain (
133
133
self . values
134
- . map ( |it| ( ItemInNs :: Values ( it. 0 ) , it. 2 . map ( ImportOrExternCrate :: Import ) ) )
135
- . into_iter ( ) ,
134
+ . map ( |it| ( ItemInNs :: Values ( it. 0 ) , it. 2 . map ( ImportOrExternCrate :: Import ) ) ) ,
136
135
)
137
136
. chain (
138
137
self . macros
139
- . map ( |it| ( ItemInNs :: Macros ( it. 0 ) , it. 2 . map ( ImportOrExternCrate :: Import ) ) )
140
- . into_iter ( ) ,
138
+ . map ( |it| ( ItemInNs :: Macros ( it. 0 ) , it. 2 . map ( ImportOrExternCrate :: Import ) ) ) ,
141
139
)
142
140
}
143
141
}
Original file line number Diff line number Diff line change @@ -239,10 +239,9 @@ fn resolve_impl_trait_item(
239
239
) -> Option < DocLinkDef > {
240
240
let canonical = ty. canonical ( ) ;
241
241
let krate = ty. krate ( db) ;
242
- let environment = resolver. generic_def ( ) . map_or_else (
243
- || crate :: TraitEnvironment :: empty ( krate. id ) . into ( ) ,
244
- |d| db. trait_environment ( d) ,
245
- ) ;
242
+ let environment = resolver
243
+ . generic_def ( )
244
+ . map_or_else ( || crate :: TraitEnvironment :: empty ( krate. id ) , |d| db. trait_environment ( d) ) ;
246
245
let traits_in_scope = resolver. traits_in_scope ( db. upcast ( ) ) ;
247
246
248
247
let mut result = None ;
Original file line number Diff line number Diff line change @@ -1744,7 +1744,7 @@ impl Config {
1744
1744
}
1745
1745
1746
1746
pub fn main_loop_num_threads ( & self ) -> usize {
1747
- self . data . numThreads . unwrap_or ( num_cpus:: get_physical ( ) . try_into ( ) . unwrap_or ( 1 ) )
1747
+ self . data . numThreads . unwrap_or ( num_cpus:: get_physical ( ) )
1748
1748
}
1749
1749
1750
1750
pub fn typing_autoclose_angle ( & self ) -> bool {
You can’t perform that action at this time.
0 commit comments