]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_error_codes/src/lib.rs
Auto merge of #84494 - tdelabro:84304-bis, r=jyn514
[rust.git] / compiler / rustc_error_codes / src / lib.rs
1 #![deny(rustdoc::invalid_codeblock_attributes)]
2 //! This library is used to gather all error codes into one place,
3 //! the goal being to make their maintenance easier.
4
5 macro_rules! register_diagnostics {
6     ($($ecode:ident: $message:expr,)* ; $($code:ident,)*) => (
7         pub static DIAGNOSTICS: &[(&str, Option<&str>)] = &[
8             $( (stringify!($ecode), Some($message)), )*
9             $( (stringify!($code), None), )*
10         ];
11     )
12 }
13
14 mod error_codes;
15 pub use error_codes::DIAGNOSTICS;