diff options
Diffstat (limited to 'crates/server/src/req.rs')
-rw-r--r-- | crates/server/src/req.rs | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/crates/server/src/req.rs b/crates/server/src/req.rs index c6d2f2efb..f52127271 100644 --- a/crates/server/src/req.rs +++ b/crates/server/src/req.rs | |||
@@ -1,6 +1,4 @@ | |||
1 | use std::collections::HashMap; | 1 | use std::collections::HashMap; |
2 | |||
3 | use serde::{ser::Serialize, de::DeserializeOwned}; | ||
4 | use languageserver_types::{TextDocumentIdentifier, Range, Url, Position, Location}; | 2 | use languageserver_types::{TextDocumentIdentifier, Range, Url, Position, Location}; |
5 | use url_serde; | 3 | use url_serde; |
6 | 4 | ||
@@ -18,24 +16,6 @@ pub use languageserver_types::{ | |||
18 | TextDocumentEdit, | 16 | TextDocumentEdit, |
19 | }; | 17 | }; |
20 | 18 | ||
21 | |||
22 | pub trait ClientRequest: 'static { | ||
23 | type Params: DeserializeOwned + Send + 'static; | ||
24 | type Result: Serialize + Send + 'static; | ||
25 | const METHOD: &'static str; | ||
26 | } | ||
27 | |||
28 | impl<T> ClientRequest for T | ||
29 | where T: Request + 'static, | ||
30 | T::Params: DeserializeOwned + Send + 'static, | ||
31 | T::Result: Serialize + Send + 'static, | ||
32 | { | ||
33 | type Params = <T as Request>::Params; | ||
34 | type Result = <T as Request>::Result; | ||
35 | const METHOD: &'static str = <T as Request>::METHOD; | ||
36 | } | ||
37 | |||
38 | |||
39 | pub enum SyntaxTree {} | 19 | pub enum SyntaxTree {} |
40 | 20 | ||
41 | impl Request for SyntaxTree { | 21 | impl Request for SyntaxTree { |