From 745892fbddea56040139108277e728b53fd8fc11 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Thu, 28 May 2020 03:03:21 +0000 Subject: CTAN sync 202005280303 --- support/texlab/src/highlight/mod.rs | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'support/texlab/src/highlight/mod.rs') diff --git a/support/texlab/src/highlight/mod.rs b/support/texlab/src/highlight/mod.rs index c6cf1fcfb9..e47a7f99c2 100644 --- a/support/texlab/src/highlight/mod.rs +++ b/support/texlab/src/highlight/mod.rs @@ -1,9 +1,11 @@ mod latex_label; use self::latex_label::LatexLabelHighlightProvider; -use crate::workspace::*; -use futures_boxed::boxed; -use lsp_types::{DocumentHighlight, TextDocumentPositionParams}; +use crate::{ + feature::{ConcatProvider, FeatureProvider, FeatureRequest}, + protocol::{DocumentHighlight, TextDocumentPositionParams}, +}; +use async_trait::async_trait; pub struct HighlightProvider { provider: ConcatProvider, @@ -23,15 +25,12 @@ impl Default for HighlightProvider { } } +#[async_trait] impl FeatureProvider for HighlightProvider { type Params = TextDocumentPositionParams; type Output = Vec; - #[boxed] - async fn execute<'a>( - &'a self, - request: &'a FeatureRequest, - ) -> Vec { - self.provider.execute(request).await + async fn execute<'a>(&'a self, req: &'a FeatureRequest) -> Self::Output { + self.provider.execute(req).await } } -- cgit v1.2.3