Rename things: Tool -> ToolModule

This commit is contained in:
Lukas Wirth 2021-12-03 17:15:19 +01:00
parent 70b8331fd5
commit d174158abc
17 changed files with 33 additions and 33 deletions

View file

@ -2039,9 +2039,9 @@ impl BuiltinAttr {
}
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
pub struct Tool(usize);
pub struct ToolModule(usize);
impl Tool {
impl ToolModule {
pub(crate) fn by_name(name: &str) -> Option<Self> {
// FIXME: def maps registered tools
hir_def::builtin_attr::TOOL_MODULES.iter().position(|&tool| tool == name).map(Self)