mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-27 05:23:24 +00:00
Get rid of failure: ra_batch ra_cli
This commit is contained in:
parent
9709bd39ca
commit
f032eeb05f
7 changed files with 7 additions and 13 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -1020,7 +1020,6 @@ dependencies = [
|
||||||
name = "ra_batch"
|
name = "ra_batch"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
|
||||||
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
"log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"ra_db 0.1.0",
|
"ra_db 0.1.0",
|
||||||
"ra_hir 0.1.0",
|
"ra_hir 0.1.0",
|
||||||
|
@ -1036,7 +1035,6 @@ name = "ra_cli"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"clap 2.33.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"clap 2.33.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"failure 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
|
||||||
"flexi_logger 0.11.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
"flexi_logger 0.11.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"indicatif 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
"indicatif 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
"join_to_string 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
"join_to_string 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||||
|
|
|
@ -66,7 +66,7 @@ use lsp_types::{
|
||||||
InitializeParams, InitializeResult, ServerCapabilities,
|
InitializeParams, InitializeResult, ServerCapabilities,
|
||||||
};
|
};
|
||||||
|
|
||||||
pub type Result<T> = ::std::result::Result<T, Box<dyn Error + Send + Sync>>;
|
pub type Result<T> = std::result::Result<T, Box<dyn Error + Send + Sync>>;
|
||||||
pub use crate::{
|
pub use crate::{
|
||||||
msg::{ErrorCode, RawMessage, RawNotification, RawRequest, RawResponse, RawResponseError},
|
msg::{ErrorCode, RawMessage, RawNotification, RawRequest, RawResponse, RawResponseError},
|
||||||
stdio::{stdio_transport, Threads},
|
stdio::{stdio_transport, Threads},
|
||||||
|
|
|
@ -8,8 +8,6 @@ authors = ["rust-analyzer developers"]
|
||||||
log = "0.4.5"
|
log = "0.4.5"
|
||||||
rustc-hash = "1.0"
|
rustc-hash = "1.0"
|
||||||
|
|
||||||
failure = "0.1.4"
|
|
||||||
|
|
||||||
ra_vfs = "0.2.0"
|
ra_vfs = "0.2.0"
|
||||||
ra_syntax = { path = "../ra_syntax" }
|
ra_syntax = { path = "../ra_syntax" }
|
||||||
ra_db = { path = "../ra_db" }
|
ra_db = { path = "../ra_db" }
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
mod vfs_filter;
|
mod vfs_filter;
|
||||||
|
|
||||||
use std::sync::Arc;
|
use std::{sync::Arc, path::Path, collections::HashSet, error::Error};
|
||||||
use std::path::Path;
|
|
||||||
use std::collections::HashSet;
|
|
||||||
|
|
||||||
use rustc_hash::FxHashMap;
|
use rustc_hash::FxHashMap;
|
||||||
|
|
||||||
|
@ -14,7 +13,7 @@ use ra_project_model::ProjectWorkspace;
|
||||||
use ra_vfs::{Vfs, VfsChange};
|
use ra_vfs::{Vfs, VfsChange};
|
||||||
use vfs_filter::IncludeRustFiles;
|
use vfs_filter::IncludeRustFiles;
|
||||||
|
|
||||||
type Result<T> = std::result::Result<T, failure::Error>;
|
type Result<T> = std::result::Result<T, Box<dyn Error + Send + Sync>>;
|
||||||
|
|
||||||
#[salsa::database(
|
#[salsa::database(
|
||||||
ra_db::SourceDatabaseStorage,
|
ra_db::SourceDatabaseStorage,
|
||||||
|
|
|
@ -7,7 +7,6 @@ publish = false
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
clap = "2.32.0"
|
clap = "2.32.0"
|
||||||
failure = "0.1.4"
|
|
||||||
join_to_string = "0.1.1"
|
join_to_string = "0.1.1"
|
||||||
flexi_logger = "0.11.0"
|
flexi_logger = "0.11.0"
|
||||||
indicatif = "0.11.0"
|
indicatif = "0.11.0"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
mod analysis_stats;
|
mod analysis_stats;
|
||||||
|
|
||||||
use std::io::Read;
|
use std::{io::Read, error::Error};
|
||||||
|
|
||||||
use clap::{App, Arg, SubCommand};
|
use clap::{App, Arg, SubCommand};
|
||||||
use ra_ide_api::{file_structure, Analysis};
|
use ra_ide_api::{file_structure, Analysis};
|
||||||
|
@ -8,7 +8,7 @@ use ra_syntax::{SourceFile, TreeArc, AstNode};
|
||||||
use flexi_logger::Logger;
|
use flexi_logger::Logger;
|
||||||
use ra_prof::profile;
|
use ra_prof::profile;
|
||||||
|
|
||||||
type Result<T> = ::std::result::Result<T, failure::Error>;
|
type Result<T> = ::std::result::Result<T, Box<dyn Error + Send + Sync>>;
|
||||||
|
|
||||||
fn main() -> Result<()> {
|
fn main() -> Result<()> {
|
||||||
Logger::with_env().start()?;
|
Logger::with_env().start()?;
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
//!
|
//!
|
||||||
//! The most interesting modules here are `syntax_node` (which defines concrete
|
//! The most interesting modules here are `syntax_node` (which defines concrete
|
||||||
//! syntax tree) and `ast` (which defines abstract syntax tree on top of the
|
//! syntax tree) and `ast` (which defines abstract syntax tree on top of the
|
||||||
//! CST). The actual parser live in a separate `ra_parser` crate, thought the
|
//! CST). The actual parser live in a separate `ra_parser` crate, though the
|
||||||
//! lexer lives in this crate.
|
//! lexer lives in this crate.
|
||||||
//!
|
//!
|
||||||
//! See `api_walkthrough` test in this file for a quick API tour!
|
//! See `api_walkthrough` test in this file for a quick API tour!
|
||||||
|
|
Loading…
Reference in a new issue