Fix clippy lints in iced_highlighter
This commit is contained in:
parent
be340a8cd8
commit
93d6f748f6
1 changed files with 3 additions and 3 deletions
|
|
@ -9,10 +9,10 @@ use syntect::highlighting;
|
||||||
use syntect::parsing;
|
use syntect::parsing;
|
||||||
|
|
||||||
static SYNTAXES: Lazy<parsing::SyntaxSet> =
|
static SYNTAXES: Lazy<parsing::SyntaxSet> =
|
||||||
Lazy::new(|| parsing::SyntaxSet::load_defaults_nonewlines());
|
Lazy::new(parsing::SyntaxSet::load_defaults_nonewlines);
|
||||||
|
|
||||||
static THEMES: Lazy<highlighting::ThemeSet> =
|
static THEMES: Lazy<highlighting::ThemeSet> =
|
||||||
Lazy::new(|| highlighting::ThemeSet::load_defaults());
|
Lazy::new(highlighting::ThemeSet::load_defaults);
|
||||||
|
|
||||||
const LINES_PER_SNAPSHOT: usize = 50;
|
const LINES_PER_SNAPSHOT: usize = 50;
|
||||||
|
|
||||||
|
|
@ -77,7 +77,7 @@ impl highlighter::Highlighter for Highlighter {
|
||||||
let (parser, stack) =
|
let (parser, stack) =
|
||||||
self.caches.last().cloned().unwrap_or_else(|| {
|
self.caches.last().cloned().unwrap_or_else(|| {
|
||||||
(
|
(
|
||||||
parsing::ParseState::new(&self.syntax),
|
parsing::ParseState::new(self.syntax),
|
||||||
parsing::ScopeStack::new(),
|
parsing::ScopeStack::new(),
|
||||||
)
|
)
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue