lsp_core::lang

Trait Lang

Source
pub trait Lang: 'static {
    type Token: PartialEq + Hash + Clone + Send + Sync + TokenTrait;
    type TokenError: Into<SimpleDiagnostic> + Send + Sync + Debug;
    type Element: Send + Sync;
    type ElementError: Into<SimpleDiagnostic> + Send + Sync + Debug;

    const CODE_ACTION: bool;
    const HOVER: bool;
    const LANG: &'static str;
    const TRIGGERS: &'static [&'static str];
    const LEGEND_TYPES: &'static [SemanticTokenType];
    const PATTERN: Option<&'static str>;
}

Required Associated Constants§

Source

const CODE_ACTION: bool

Source

const HOVER: bool

Source

const LANG: &'static str

Source

const TRIGGERS: &'static [&'static str]

Source

const LEGEND_TYPES: &'static [SemanticTokenType]

Source

const PATTERN: Option<&'static str>

Required Associated Types§

Source

type Token: PartialEq + Hash + Clone + Send + Sync + TokenTrait

Type of tokens after tokenization

Source

type TokenError: Into<SimpleDiagnostic> + Send + Sync + Debug

Source

type Element: Send + Sync

Type of Element inside a ParentingSystem

Source

type ElementError: Into<SimpleDiagnostic> + Send + Sync + Debug

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§