1#[doc = include_str!("../readme.md")]
2use crate::{ast::AdaRoot, lexer::AdaTokenType, parser::AdaElementType};
3use oak_core::{Language, LanguageCategory};
4use serde::{Deserialize, Serialize};
5
6#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
8pub struct AdaLanguage {
9 pub allow_ada_2022: bool,
11 pub strict_mode: bool,
13}
14
15impl Default for AdaLanguage {
16 fn default() -> Self {
17 Self { allow_ada_2022: true, strict_mode: false }
18 }
19}
20
21impl Language for AdaLanguage {
22 const NAME: &'static str = "ada";
23 const CATEGORY: LanguageCategory = LanguageCategory::Programming;
24
25 type TokenType = AdaTokenType;
26 type ElementType = AdaElementType;
27 type TypedRoot = AdaRoot;
28}