1
0
dust/src/abstract_tree/match.rs
2023-11-30 00:57:15 -05:00

27 lines
693 B
Rust

//! Pattern matching.
//!
//! Note that this module is called "match" but is escaped as "r#match" because
//! "match" is a keyword in Rust.
use serde::{Deserialize, Serialize};
use tree_sitter::Node;
use crate::{AbstractTree, Map, Result, TypeDefinition, Value};
#[derive(Debug, Clone, Serialize, Deserialize, Eq, PartialEq, PartialOrd, Ord)]
pub struct Match {}
impl AbstractTree for Match {
fn from_syntax_node(_source: &str, _node: Node, _context: &Map) -> Result<Self> {
todo!()
}
fn run(&self, _source: &str, _context: &Map) -> Result<Value> {
todo!()
}
fn expected_type(&self, _context: &Map) -> Result<TypeDefinition> {
todo!()
}
}