PR issuse resolved

This commit is contained in:
Sergey Parilin 2019-04-02 17:52:04 +03:00
parent ef02c3c038
commit 9b73f80959
9 changed files with 30 additions and 10 deletions

View file

@ -1,6 +1,6 @@
mod analysis_stats;
use std::{fs, io::Read, path::Path, time::Instant};
use std::{fs, io::Read, path::Path};
use clap::{App, Arg, SubCommand};
use join_to_string::join;
@ -9,6 +9,7 @@ use ra_ide_api_light::file_structure;
use ra_syntax::{SourceFile, TextRange, TreeArc, AstNode};
use tools::collect_tests;
use flexi_logger::Logger;
use ra_prof::profile;
type Result<T> = ::std::result::Result<T, failure::Error>;
@ -34,13 +35,11 @@ fn main() -> Result<()> {
.get_matches();
match matches.subcommand() {
("parse", Some(matches)) => {
let start = Instant::now();
let _p = profile("parsing");
let file = file()?;
let elapsed = start.elapsed();
if !matches.is_present("no-dump") {
println!("{}", file.syntax().debug_dump());
}
eprintln!("parsing: {:?}", elapsed);
::std::mem::forget(file);
}
("symbols", _) => {