⚠️ VeridianOS Kernel Documentation - This is low-level kernel code. All functions are unsafe unless explicitly marked otherwise. no_std

SyntaxHighlighter

Trait SyntaxHighlighter 

Source
pub trait SyntaxHighlighter {
    // Required methods
    fn tokenize_line(&self, line: &str) -> Vec<SyntaxToken>;
    fn language(&self) -> Language;
}
Expand description

Language-specific line tokenizer.

Required Methods§

Source

fn tokenize_line(&self, line: &str) -> Vec<SyntaxToken>

Break a single line into a sequence of colored tokens.

Source

fn language(&self) -> Language

The language this highlighter handles.

Implementors§