Can collect webidl paths.

This commit is contained in:
krk 2019-04-14 14:16:38 +02:00
parent 328244684a
commit dfca8ec913
5 changed files with 144 additions and 1 deletions

View file

@ -31,6 +31,9 @@ use syntax::feature_gate::AttributeType::Whitelisted;
#[cfg(feature = "unrooted_must_root_lint")]
mod unrooted_must_root;
#[cfg(feature = "webidl_lint")]
mod webidl_must_inherit;
/// Utilities for writing plugins
#[cfg(feature = "unrooted_must_root_lint")]
mod utils;
@ -40,7 +43,11 @@ pub fn plugin_registrar(reg: &mut Registry) {
#[cfg(feature = "unrooted_must_root_lint")]
reg.register_late_lint_pass(Box::new(unrooted_must_root::UnrootedPass::new()));
#[cfg(feature = "webidl_lint")]
reg.register_late_lint_pass(Box::new(webidl_must_inherit::WebIdlPass::new()));
reg.register_attribute("allow_unrooted_interior".to_string(), Whitelisted);
reg.register_attribute("allow_unrooted_in_rc".to_string(), Whitelisted);
reg.register_attribute("must_root".to_string(), Whitelisted);
reg.register_attribute("webidl".to_string(), Whitelisted);
}