mirror of
https://github.com/YGGverse/Yoda.git
synced 2025-01-15 17:20:08 +00:00
add find_syntax_by_path method in order
This commit is contained in:
parent
15a63a21c9
commit
fe9c859f7f
@ -40,6 +40,10 @@ impl Syntax {
|
||||
if let Some(reference) = self.syntax_set.find_syntax_by_token(value) {
|
||||
return self.syntect_buffer(source_code, source_tag, reference);
|
||||
}
|
||||
|
||||
if let Some(reference) = self.syntax_set.find_syntax_by_path(value) {
|
||||
return self.syntect_buffer(source_code, source_tag, reference);
|
||||
}
|
||||
}
|
||||
|
||||
if let Some(reference) = self.syntax_set.find_syntax_by_first_line(source_code) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user