From 072028e67996162f5a9da14cfd59ed64de5e8729 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Fri, 28 Dec 2018 13:27:30 +0300 Subject: add macro-call node --- crates/ra_analysis/src/syntax_highlighting.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'crates/ra_analysis/src') diff --git a/crates/ra_analysis/src/syntax_highlighting.rs b/crates/ra_analysis/src/syntax_highlighting.rs index 65409beb2..0bf19eea0 100644 --- a/crates/ra_analysis/src/syntax_highlighting.rs +++ b/crates/ra_analysis/src/syntax_highlighting.rs @@ -7,6 +7,8 @@ use crate::{ }; pub(crate) fn highlight(db: &RootDatabase, file_id: FileId) -> Cancelable> { - let file = db.source_file(file_id); - Ok(ra_editor::highlight(&file)) + let source_file = db.source_file(file_id); + let mut res = ra_editor::highlight(&source_file); + for node in source_file.syntax().descendants() {} + Ok(res) } -- cgit v1.2.3