Skip to main content

oak_vala/
lib.rs

1#![doc = include_str!("readme.md")]
2#![feature(new_range_api)]
3#![warn(missing_docs)]
4#![doc(html_logo_url = "https://raw.githubusercontent.com/ygg-lang/oaks/refs/heads/dev/documents/logo.svg")]
5#![doc(html_favicon_url = "https://raw.githubusercontent.com/ygg-lang/oaks/refs/heads/dev/documents/logo.svg")]
6//! Vala support for the Oak language framework.
7
8/// AST module.
9pub mod ast;
10/// Builder module.
11pub mod builder;
12
13/// Type definitions module.
14/// Language configuration module.
15pub mod language;
16/// Lexer module.
17pub mod lexer;
18/// LSP module.
19#[cfg(any(feature = "lsp", feature = "oak-highlight", feature = "oak-pretty-print"))]
20pub mod lsp;
21/// MCP module.
22#[cfg(feature = "mcp")]
23pub mod mcp;
24
25/// Parser module.
26pub mod parser;
27
28pub use crate::{
29    ast::ValaRoot,
30    builder::ValaBuilder,
31    language::ValaLanguage,
32    lexer::{ValaLexer, token_type::ValaTokenType},
33    parser::{ValaParser, element_type::ValaElementType},
34};
35
36/// Highlighter implementation.
37#[cfg(feature = "oak-highlight")]
38pub use crate::lsp::highlighter::ValaHighlighter;
39
40#[cfg(feature = "lsp")]
41pub use crate::lsp::ValaLanguageService;
42/// LSP implementation.
43#[cfg(feature = "lsp")]
44pub use crate::lsp::formatter::ValaFormatter;
45
46/// MCP service implementation.
47#[cfg(feature = "mcp")]
48pub use crate::mcp::serve_vala_mcp;