-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use path dependency instead of rustc_private
- Loading branch information
Showing
2 changed files
with
9 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 4 additions & 18 deletions
22
src/tools/rust-analyzer/crates/rustc-dependencies/src/lib.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,34 @@ | ||
//! A wrapper around rustc internal crates, which enables switching between compiler provided | ||
//! ones and stable ones published in crates.io | ||
#![cfg_attr(feature = "in-rust-tree", feature(rustc_private))] | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
extern crate rustc_lexer; | ||
|
||
pub mod lexer { | ||
#[cfg(not(feature = "in-rust-tree"))] | ||
pub use ::ra_ap_rustc_lexer::*; | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
pub use ::rustc_lexer::*; | ||
pub use ::in_tree_rustc_lexer::*; | ||
} | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
extern crate rustc_parse_format; | ||
|
||
pub mod parse_format { | ||
#[cfg(not(feature = "in-rust-tree"))] | ||
pub use ::ra_ap_rustc_parse_format::*; | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
pub use ::rustc_parse_format::*; | ||
pub use ::in_tree_rustc_parse_format::*; | ||
} | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
extern crate rustc_abi; | ||
|
||
pub mod abi { | ||
#[cfg(not(feature = "in-rust-tree"))] | ||
pub use ::ra_ap_rustc_abi::*; | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
pub use ::rustc_abi::*; | ||
pub use ::in_tree_rustc_abi::*; | ||
} | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
extern crate rustc_index; | ||
|
||
pub mod index { | ||
#[cfg(not(feature = "in-rust-tree"))] | ||
pub use ::ra_ap_rustc_index::*; | ||
|
||
#[cfg(feature = "in-rust-tree")] | ||
pub use ::rustc_index::*; | ||
pub use ::in_tree_rustc_index::*; | ||
} |