mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 04:19:13 +00:00
Simplify event processing
This commit is contained in:
parent
3c12d38a32
commit
86a7ac2d31
6 changed files with 128 additions and 104 deletions
|
@ -74,7 +74,8 @@ impl File {
|
|||
}
|
||||
pub fn parse(text: &str) -> File {
|
||||
let tokens = tokenize(&text);
|
||||
let (green, errors) = parser_impl::parse_with::<yellow::GreenBuilder>(
|
||||
let (green, errors) = parser_impl::parse_with(
|
||||
yellow::GreenBuilder::new(),
|
||||
text, &tokens, grammar::root,
|
||||
);
|
||||
File::new(green, errors)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue