Skip to main content

oak_ada/formatter/
mod.rs

1#![doc = include_str!("../readme.md")]
2
3use crate::ast::AdaRoot;
4
5/// Ada Code Formatter
6pub struct AdaFormatter;
7
8impl AdaFormatter {
9    /// Create a new Ada formatter
10    pub fn new() -> Self {
11        Self
12    }
13
14    /// Format the given Ada source code string
15    pub fn format(&self, source: &str) -> String {
16        self.basic_format(source)
17    }
18
19    fn basic_format(&self, source: &str) -> String {
20        source.to_string()
21    }
22
23    /// Format Ada AST root node
24    pub fn format_root(&self, _root: &AdaRoot) -> String {
25        "TODO: Implement Ada AST formatting".to_string()
26    }
27}
28
29impl Default for AdaFormatter {
30    fn default() -> Self {
31        Self::new()
32    }
33}