Source code for topos.graphs.ast.providers.base

from __future__ import annotations

from typing import Protocol

from topos.graphs.ast.types import ParseResult


[docs] class AstProvider(Protocol): """Protocol for language-aware parser backends.""" name: str
[docs] def supports(self, language: str) -> bool: ...
[docs] def parse(
self, source: str, language: str, file: str | None = None ) -> ParseResult: ...