Skip to main content

oak_ocaml/language/
mod.rs

1use crate::ast::OCamlRoot;
2use oak_core::{Language, LanguageCategory};
3use serde::{Deserialize, Serialize};
4
5#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, Default)]
6pub struct OCamlLanguage {}
7
8impl OCamlLanguage {
9    pub fn new() -> Self {
10        Self {}
11    }
12}
13
14impl Language for OCamlLanguage {
15    const NAME: &'static str = "ocaml";
16    const CATEGORY: LanguageCategory = LanguageCategory::Programming;
17
18    type TokenType = crate::kind::OCamlSyntaxKind;
19    type ElementType = crate::kind::OCamlSyntaxKind;
20    type TypedRoot = OCamlRoot;
21}