mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 04:44:57 +00:00
switch to new rowan
This commit is contained in:
parent
dec9bde108
commit
9e213385c9
50 changed files with 1026 additions and 1227 deletions
|
@ -40,15 +40,15 @@ pub trait TokenSource {
|
|||
|
||||
/// `TreeSink` abstracts details of a particular syntax tree implementation.
|
||||
pub trait TreeSink {
|
||||
/// Adds new leaf to the current branch.
|
||||
fn leaf(&mut self, kind: SyntaxKind, n_tokens: u8);
|
||||
/// Adds new token to the current branch.
|
||||
fn token(&mut self, kind: SyntaxKind, n_tokens: u8);
|
||||
|
||||
/// Start new branch and make it current.
|
||||
fn start_branch(&mut self, kind: SyntaxKind);
|
||||
fn start_node(&mut self, kind: SyntaxKind);
|
||||
|
||||
/// Finish current branch and restore previous
|
||||
/// branch as current.
|
||||
fn finish_branch(&mut self);
|
||||
fn finish_node(&mut self);
|
||||
|
||||
fn error(&mut self, error: ParseError);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue