internal: Move grammar codegen into xtask

This commit is contained in:
Lukas Wirth 2024-03-19 10:40:36 +01:00
parent 232125be12
commit b38d5394bb
14 changed files with 448 additions and 405 deletions

View file

@ -9,6 +9,7 @@ use crate::{flags, project_root};
pub(crate) mod assists_doc_tests;
pub(crate) mod diagnostics_docs;
mod grammar;
mod lints;
impl flags::Codegen {
@ -20,6 +21,7 @@ impl flags::Codegen {
// lints::generate(self.check) Updating clones the rust repo, so don't run it unless
// explicitly asked for
}
flags::CodegenType::Grammar => grammar::generate(self.check),
flags::CodegenType::AssistsDocTests => assists_doc_tests::generate(self.check),
flags::CodegenType::DiagnosticsDocs => diagnostics_docs::generate(self.check),
flags::CodegenType::LintDefinitions => lints::generate(self.check),