2020-01-13 13:40:30 +01:00
|
|
|
//! Various checks
|
|
|
|
//!
|
|
|
|
//! # Note
|
|
|
|
//!
|
|
|
|
//! This API is completely unstable and subject to change.
|
|
|
|
|
2020-09-23 21:51:56 +02:00
|
|
|
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
|
2023-02-18 19:21:07 -08:00
|
|
|
#![feature(assert_matches)]
|
2023-04-02 23:21:09 -07:00
|
|
|
#![feature(iterator_try_collect)]
|
2022-09-30 18:53:32 +01:00
|
|
|
#![feature(let_chains)]
|
2022-07-09 09:35:06 +00:00
|
|
|
#![feature(never_type)]
|
|
|
|
#![feature(box_patterns)]
|
2020-01-13 13:40:30 +01:00
|
|
|
#![recursion_limit = "256"]
|
2023-04-08 20:01:14 +01:00
|
|
|
#![deny(rustc::untranslatable_diagnostic)]
|
|
|
|
#![deny(rustc::diagnostic_outside_of_impl)]
|
2020-01-13 13:40:30 +01:00
|
|
|
|
|
|
|
#[macro_use]
|
2020-03-29 16:41:09 +02:00
|
|
|
extern crate rustc_middle;
|
2020-01-13 13:40:30 +01:00
|
|
|
#[macro_use]
|
2020-08-13 23:05:01 -07:00
|
|
|
extern crate tracing;
|
2020-01-13 13:40:30 +01:00
|
|
|
|
2022-10-13 10:13:02 +01:00
|
|
|
use rustc_errors::{DiagnosticMessage, SubdiagnosticMessage};
|
2023-04-16 14:33:00 +02:00
|
|
|
use rustc_fluent_macro::fluent_messages;
|
2023-05-15 06:24:45 +02:00
|
|
|
use rustc_middle::query::Providers;
|
2020-01-13 13:40:30 +01:00
|
|
|
|
2022-10-02 19:06:14 -05:00
|
|
|
mod abi;
|
2021-11-18 21:44:45 +00:00
|
|
|
mod assoc;
|
2020-01-30 20:28:16 +00:00
|
|
|
mod common_traits;
|
2022-06-28 22:45:05 +02:00
|
|
|
mod consts;
|
2022-08-19 00:04:31 +01:00
|
|
|
mod errors;
|
2022-08-17 12:22:32 +02:00
|
|
|
mod implied_bounds;
|
2020-02-12 17:24:32 +01:00
|
|
|
pub mod instance;
|
2022-10-02 19:06:14 -05:00
|
|
|
mod layout;
|
|
|
|
mod layout_sanity_check;
|
2020-01-30 20:28:16 +00:00
|
|
|
mod needs_drop;
|
2023-04-18 16:09:48 +02:00
|
|
|
mod opaque_types;
|
2021-04-27 15:01:37 +02:00
|
|
|
pub mod representability;
|
2022-12-08 04:02:50 +00:00
|
|
|
mod structural_match;
|
2020-01-13 13:40:30 +01:00
|
|
|
mod ty;
|
|
|
|
|
2023-03-03 00:18:38 +01:00
|
|
|
fluent_messages! { "../messages.ftl" }
|
2022-10-13 10:13:02 +01:00
|
|
|
|
2020-07-05 23:00:14 +03:00
|
|
|
pub fn provide(providers: &mut Providers) {
|
2022-10-02 19:06:14 -05:00
|
|
|
abi::provide(providers);
|
2021-11-18 21:44:45 +00:00
|
|
|
assoc::provide(providers);
|
2020-01-30 20:28:16 +00:00
|
|
|
common_traits::provide(providers);
|
2022-06-28 22:35:48 +02:00
|
|
|
consts::provide(providers);
|
2022-08-17 12:22:32 +02:00
|
|
|
implied_bounds::provide(providers);
|
2022-10-02 19:06:14 -05:00
|
|
|
layout::provide(providers);
|
2020-01-30 20:28:16 +00:00
|
|
|
needs_drop::provide(providers);
|
2023-04-18 16:09:48 +02:00
|
|
|
opaque_types::provide(providers);
|
2022-08-15 14:11:11 -05:00
|
|
|
representability::provide(providers);
|
2020-01-13 13:40:30 +01:00
|
|
|
ty::provide(providers);
|
2020-04-05 01:21:36 -04:00
|
|
|
instance::provide(providers);
|
2022-12-08 04:02:50 +00:00
|
|
|
structural_match::provide(providers);
|
2020-01-13 13:40:30 +01:00
|
|
|
}
|