2016-01-15 13:16:54 +01:00
|
|
|
//! Various checks
|
|
|
|
//!
|
|
|
|
//! # Note
|
|
|
|
//!
|
|
|
|
//! This API is completely unstable and subject to change.
|
|
|
|
|
2022-02-28 15:52:36 -03:00
|
|
|
#![allow(rustc::potential_query_instability)]
|
2020-09-23 21:51:56 +02:00
|
|
|
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
|
2022-01-15 19:57:47 +01:00
|
|
|
#![feature(iter_intersperse)]
|
2022-08-20 20:40:08 +02:00
|
|
|
#![feature(let_chains)]
|
2021-10-01 20:54:36 +02:00
|
|
|
#![feature(map_try_insert)]
|
2021-04-02 00:58:45 -04:00
|
|
|
#![feature(min_specialization)]
|
2021-06-23 18:37:26 +08:00
|
|
|
#![feature(try_blocks)]
|
2018-12-13 16:57:25 +01:00
|
|
|
#![recursion_limit = "256"]
|
2023-04-25 18:42:42 +01:00
|
|
|
#![deny(rustc::untranslatable_diagnostic)]
|
|
|
|
#![deny(rustc::diagnostic_outside_of_impl)]
|
2018-12-13 16:57:25 +01:00
|
|
|
|
2016-07-21 07:01:14 +05:30
|
|
|
#[macro_use]
|
2020-03-29 16:41:09 +02:00
|
|
|
extern crate rustc_middle;
|
2019-10-04 10:37:40 -04:00
|
|
|
#[macro_use]
|
2020-08-13 23:05:01 -07:00
|
|
|
extern crate tracing;
|
2016-01-15 13:16:54 +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;
|
2017-09-11 13:09:14 -04:00
|
|
|
|
2020-01-01 17:27:30 +01:00
|
|
|
mod check_attr;
|
2019-11-06 11:44:56 -08:00
|
|
|
mod check_const;
|
2019-10-04 10:33:11 -04:00
|
|
|
pub mod dead;
|
2022-04-25 18:02:43 -07:00
|
|
|
mod debugger_visualizer;
|
2019-12-26 23:33:40 +01:00
|
|
|
mod diagnostic_items;
|
2019-10-04 10:37:40 -04:00
|
|
|
pub mod entry;
|
2022-07-11 18:59:04 +01:00
|
|
|
mod errors;
|
2020-03-24 04:59:39 +01:00
|
|
|
pub mod hir_id_validator;
|
2019-10-04 10:31:28 -04:00
|
|
|
pub mod hir_stats;
|
2020-01-31 23:06:06 +01:00
|
|
|
mod lang_items;
|
2019-01-09 15:16:32 -05:00
|
|
|
pub mod layout_test;
|
2019-12-27 18:52:36 +01:00
|
|
|
mod lib_features;
|
2019-12-22 17:42:04 -05:00
|
|
|
mod liveness;
|
2016-01-21 10:52:37 +01:00
|
|
|
pub mod loops;
|
2020-11-25 00:00:00 +00:00
|
|
|
mod naked_functions;
|
2019-12-26 23:24:36 +01:00
|
|
|
mod reachable;
|
2019-12-29 11:20:20 +01:00
|
|
|
pub mod stability;
|
2020-01-01 17:31:03 +01:00
|
|
|
mod upvars;
|
2019-12-28 18:31:37 +01:00
|
|
|
mod weak_lang_items;
|
2017-07-30 23:22:09 -07:00
|
|
|
|
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) {
|
2020-01-01 17:27:30 +01:00
|
|
|
check_attr::provide(providers);
|
2019-11-06 11:44:56 -08:00
|
|
|
check_const::provide(providers);
|
2022-01-29 21:10:41 +01:00
|
|
|
dead::provide(providers);
|
2022-04-25 18:02:43 -07:00
|
|
|
debugger_visualizer::provide(providers);
|
2019-12-26 23:33:40 +01:00
|
|
|
diagnostic_items::provide(providers);
|
2019-10-04 10:37:40 -04:00
|
|
|
entry::provide(providers);
|
2020-01-31 23:06:06 +01:00
|
|
|
lang_items::provide(providers);
|
2019-12-27 18:52:36 +01:00
|
|
|
lib_features::provide(providers);
|
2018-06-06 22:13:52 +02:00
|
|
|
loops::provide(providers);
|
2020-11-25 00:00:00 +00:00
|
|
|
naked_functions::provide(providers);
|
2019-10-04 10:31:28 -04:00
|
|
|
liveness::provide(providers);
|
2019-12-26 23:24:36 +01:00
|
|
|
reachable::provide(providers);
|
2019-12-29 11:20:20 +01:00
|
|
|
stability::provide(providers);
|
2020-01-01 17:31:03 +01:00
|
|
|
upvars::provide(providers);
|
2017-09-11 13:09:14 -04:00
|
|
|
}
|