]> git.proxmox.com Git - rustc.git/blob - compiler/rustc_passes/src/lib.rs
0cb8424082c3e0e053ca21f7e0292d1984cc1386
[rustc.git] / compiler / rustc_passes / src / lib.rs
1 //! Various checks
2 //!
3 //! # Note
4 //!
5 //! This API is completely unstable and subject to change.
6
7 #![allow(rustc::potential_query_instability)]
8 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
9 #![feature(iter_intersperse)]
10 #![feature(let_chains)]
11 #![feature(map_try_insert)]
12 #![feature(min_specialization)]
13 #![feature(try_blocks)]
14 #![recursion_limit = "256"]
15
16 #[macro_use]
17 extern crate rustc_middle;
18 #[macro_use]
19 extern crate tracing;
20
21 use rustc_errors::{DiagnosticMessage, SubdiagnosticMessage};
22 use rustc_macros::fluent_messages;
23 use rustc_middle::ty::query::Providers;
24
25 mod check_attr;
26 mod check_const;
27 pub mod dead;
28 mod debugger_visualizer;
29 mod diagnostic_items;
30 pub mod entry;
31 mod errors;
32 pub mod hir_id_validator;
33 pub mod hir_stats;
34 mod lang_items;
35 pub mod layout_test;
36 mod lib_features;
37 mod liveness;
38 pub mod loops;
39 mod naked_functions;
40 mod reachable;
41 pub mod stability;
42 mod upvars;
43 mod weak_lang_items;
44
45 fluent_messages! { "../locales/en-US.ftl" }
46
47 pub fn provide(providers: &mut Providers) {
48 check_attr::provide(providers);
49 check_const::provide(providers);
50 dead::provide(providers);
51 debugger_visualizer::provide(providers);
52 diagnostic_items::provide(providers);
53 entry::provide(providers);
54 lang_items::provide(providers);
55 lib_features::provide(providers);
56 loops::provide(providers);
57 naked_functions::provide(providers);
58 liveness::provide(providers);
59 reachable::provide(providers);
60 stability::provide(providers);
61 upvars::provide(providers);
62 }