Move to new crate rustc_ty.
This commit is contained in:
parent
6d5170c960
commit
9908a87367
6 changed files with 54 additions and 2 deletions
12
Cargo.lock
12
Cargo.lock
|
@ -3642,6 +3642,7 @@ dependencies = [
|
||||||
"rustc_span",
|
"rustc_span",
|
||||||
"rustc_target",
|
"rustc_target",
|
||||||
"rustc_traits",
|
"rustc_traits",
|
||||||
|
"rustc_ty",
|
||||||
"rustc_typeck",
|
"rustc_typeck",
|
||||||
"serialize",
|
"serialize",
|
||||||
"smallvec 1.0.0",
|
"smallvec 1.0.0",
|
||||||
|
@ -3918,6 +3919,17 @@ dependencies = [
|
||||||
"syntax",
|
"syntax",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "rustc_ty"
|
||||||
|
version = "0.0.0"
|
||||||
|
dependencies = [
|
||||||
|
"log",
|
||||||
|
"rustc",
|
||||||
|
"rustc_data_structures",
|
||||||
|
"rustc_hir",
|
||||||
|
"rustc_span",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "rustc_typeck"
|
name = "rustc_typeck"
|
||||||
version = "0.0.0"
|
version = "0.0.0"
|
||||||
|
|
|
@ -39,6 +39,7 @@ rustc_errors = { path = "../librustc_errors" }
|
||||||
rustc_plugin_impl = { path = "../librustc_plugin_impl" }
|
rustc_plugin_impl = { path = "../librustc_plugin_impl" }
|
||||||
rustc_privacy = { path = "../librustc_privacy" }
|
rustc_privacy = { path = "../librustc_privacy" }
|
||||||
rustc_resolve = { path = "../librustc_resolve" }
|
rustc_resolve = { path = "../librustc_resolve" }
|
||||||
|
rustc_ty = { path = "../librustc_ty" }
|
||||||
tempfile = "3.0.5"
|
tempfile = "3.0.5"
|
||||||
once_cell = "1"
|
once_cell = "1"
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,6 @@ pub mod loops;
|
||||||
mod reachable;
|
mod reachable;
|
||||||
mod region;
|
mod region;
|
||||||
pub mod stability;
|
pub mod stability;
|
||||||
mod ty;
|
|
||||||
|
|
||||||
pub fn provide(providers: &mut Providers<'_>) {
|
pub fn provide(providers: &mut Providers<'_>) {
|
||||||
check_const::provide(providers);
|
check_const::provide(providers);
|
||||||
|
@ -44,5 +43,4 @@ pub fn provide(providers: &mut Providers<'_>) {
|
||||||
reachable::provide(providers);
|
reachable::provide(providers);
|
||||||
region::provide(providers);
|
region::provide(providers);
|
||||||
stability::provide(providers);
|
stability::provide(providers);
|
||||||
ty::provide(providers);
|
|
||||||
}
|
}
|
||||||
|
|
16
src/librustc_ty/Cargo.toml
Normal file
16
src/librustc_ty/Cargo.toml
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
[package]
|
||||||
|
authors = ["The Rust Project Developers"]
|
||||||
|
name = "rustc_ty"
|
||||||
|
version = "0.0.0"
|
||||||
|
edition = "2018"
|
||||||
|
|
||||||
|
[lib]
|
||||||
|
name = "rustc_ty"
|
||||||
|
path = "lib.rs"
|
||||||
|
|
||||||
|
[dependencies]
|
||||||
|
log = "0.4"
|
||||||
|
rustc = { path = "../librustc" }
|
||||||
|
rustc_data_structures = { path = "../librustc_data_structures" }
|
||||||
|
rustc_hir = { path = "../librustc_hir" }
|
||||||
|
rustc_span = { path = "../librustc_span" }
|
25
src/librustc_ty/lib.rs
Normal file
25
src/librustc_ty/lib.rs
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
//! Various checks
|
||||||
|
//!
|
||||||
|
//! # Note
|
||||||
|
//!
|
||||||
|
//! This API is completely unstable and subject to change.
|
||||||
|
|
||||||
|
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
|
||||||
|
#![feature(bool_to_option)]
|
||||||
|
#![feature(in_band_lifetimes)]
|
||||||
|
#![feature(nll)]
|
||||||
|
#![feature(slice_patterns)]
|
||||||
|
#![recursion_limit = "256"]
|
||||||
|
|
||||||
|
#[macro_use]
|
||||||
|
extern crate rustc;
|
||||||
|
#[macro_use]
|
||||||
|
extern crate log;
|
||||||
|
|
||||||
|
use rustc::ty::query::Providers;
|
||||||
|
|
||||||
|
mod ty;
|
||||||
|
|
||||||
|
pub fn provide(providers: &mut Providers<'_>) {
|
||||||
|
ty::provide(providers);
|
||||||
|
}
|
Loading…
Add table
Reference in a new issue