]> git.lizzy.rs Git - rust.git/blob - src/librustc_plugin_impl/lib.rs
Rollup merge of #68511 - tmiasko:ignore-license, r=alexcrichton
[rust.git] / src / librustc_plugin_impl / lib.rs
1 //! Infrastructure for compiler plugins.
2 //!
3 //! Plugins are a deprecated way to extend the behavior of `rustc` in various ways.
4 //!
5 //! See the [`plugin`
6 //! feature](https://doc.rust-lang.org/nightly/unstable-book/language-features/plugin.html)
7 //! of the Unstable Book for some examples.
8
9 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/")]
10 #![feature(nll)]
11
12 use rustc_lint::LintStore;
13
14 pub mod build;
15 pub mod load;
16
17 /// Structure used to register plugins.
18 ///
19 /// A plugin registrar function takes an `&mut Registry` and should call
20 /// methods to register its plugins.
21 pub struct Registry<'a> {
22     /// The `LintStore` allows plugins to register new lints.
23     pub lint_store: &'a mut LintStore,
24 }