-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Convert to std::future::Future and async/await
This commit makes judicious use of `compat()` to convert between `std::future::Future` and the legacy `futures` 0.1 `Future` trait such that we can have native Rust async/await support without waiting for the `jsonrpsee` crate to be ready (see #58 for context). Naturally, this should be considered a breaking change for this library since it directly affects the public API for this crate, and it also increases the minimum supported Rust version to 1.39.0. It tentatively introduces a reliance on [`async-trait`] for the `LanguageServer` trait and it also relaxes the `'static` requirements for the `stdin` parameter for `Server`. [`async-trait`]: https://github.com/dtolnay/async-trait This does not yet resolve #13, since that would require either switching to `jsonrpsee`, once it's ready, or building a custom client solution for the `Printer`, converting it to a `Client` or similar.
- Loading branch information
1 parent
cdad611
commit 76f9a8a
Showing
10 changed files
with
493 additions
and
416 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.