mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-23 13:13:17 +00:00
token source scaffold
This commit is contained in:
parent
e9cafafbc2
commit
10deefd371
@ -1,5 +1,6 @@
|
||||
use ra_parser::TokenSource;
|
||||
use ra_syntax::{
|
||||
AstNode, SyntaxNode, TextRange,
|
||||
AstNode, SyntaxNode, TextRange, SyntaxKind,
|
||||
ast, SyntaxKind::*, TextUnit
|
||||
};
|
||||
|
||||
@ -89,3 +90,23 @@ fn convert_tt(
|
||||
let res = tt::Subtree { delimiter, token_trees };
|
||||
Some(res)
|
||||
}
|
||||
|
||||
struct TtTokenSource;
|
||||
|
||||
impl TtTokenSource {
|
||||
fn new(tt: &tt::Subtree) -> TtTokenSource {
|
||||
unimplemented!()
|
||||
}
|
||||
}
|
||||
|
||||
impl TokenSource for TtTokenSource {
|
||||
fn token_kind(&self, pos: usize) -> SyntaxKind {
|
||||
unimplemented!()
|
||||
}
|
||||
fn is_token_joint_to_next(&self, pos: usize) -> bool {
|
||||
unimplemented!()
|
||||
}
|
||||
fn is_keyword(&self, pos: usize, kw: &str) -> bool {
|
||||
unimplemented!()
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user