@@ -50,12 +50,7 @@ impl<'a> Extractor<'a> {
5050 }
5151 }
5252
53- fn extract (
54- & mut self ,
55- rust_analyzer : & RustAnalyzer ,
56- file : & Path ,
57- source_kind : SourceKind ,
58- ) {
53+ fn extract ( & mut self , rust_analyzer : & RustAnalyzer , file : & Path , source_kind : SourceKind ) {
5954 self . archiver . archive ( file) ;
6055 let before_parse = Instant :: now ( ) ;
6156 let ParseResult {
@@ -118,11 +113,7 @@ impl<'a> Extractor<'a> {
118113 vfs : & Vfs ,
119114 source_kind : SourceKind ,
120115 ) {
121- self . extract (
122- & RustAnalyzer :: new ( vfs, semantics) ,
123- file,
124- source_kind,
125- ) ;
116+ self . extract ( & RustAnalyzer :: new ( vfs, semantics) , file, source_kind) ;
126117 }
127118
128119 pub fn extract_without_semantics (
@@ -131,11 +122,7 @@ impl<'a> Extractor<'a> {
131122 source_kind : SourceKind ,
132123 err : RustAnalyzerNoSemantics ,
133124 ) {
134- self . extract (
135- & RustAnalyzer :: from ( err) ,
136- file,
137- source_kind,
138- ) ;
125+ self . extract ( & RustAnalyzer :: from ( err) , file, source_kind) ;
139126 }
140127
141128 pub fn load_manifest (
@@ -308,12 +295,7 @@ fn main() -> anyhow::Result<()> {
308295 let semantics = Semantics :: new ( db) ;
309296 for file in files {
310297 match extractor. load_source ( file, & semantics, vfs) {
311- Ok ( ( ) ) => extractor. extract_with_semantics (
312- file,
313- & semantics,
314- vfs,
315- source_mode,
316- ) ,
298+ Ok ( ( ) ) => extractor. extract_with_semantics ( file, & semantics, vfs, source_mode) ,
317299 Err ( e) => extractor. extract_without_semantics ( file, source_mode, e) ,
318300 } ;
319301 }
@@ -326,12 +308,7 @@ fn main() -> anyhow::Result<()> {
326308 . source_root ( db)
327309 . is_library
328310 {
329- extractor. extract_with_semantics (
330- file,
331- & semantics,
332- vfs,
333- library_mode,
334- ) ;
311+ extractor. extract_with_semantics ( file, & semantics, vfs, library_mode) ;
335312 extractor. archiver . archive ( file) ;
336313 }
337314 }
0 commit comments