diff options
author | jbeich <jbeich@FreeBSD.org> | 2019-01-03 11:49:57 +0800 |
---|---|---|
committer | jbeich <jbeich@FreeBSD.org> | 2019-01-03 11:49:57 +0800 |
commit | 8cceca34ab9f61ba67eddccc8cb6c2502c3ac441 (patch) | |
tree | 03c4627feb4a246239c75ce04dae0ba871239ba2 /lang/rust-nightly | |
parent | 7c5b18afed3b371f50695a977e661b18bcfe245c (diff) | |
download | freebsd-ports-gnome-8cceca34ab9f61ba67eddccc8cb6c2502c3ac441.tar.gz freebsd-ports-gnome-8cceca34ab9f61ba67eddccc8cb6c2502c3ac441.tar.zst freebsd-ports-gnome-8cceca34ab9f61ba67eddccc8cb6c2502c3ac441.zip |
lang/rust-nightly: unbreak after r489123
error[E0621]: explicit lifetime required in the type of `msg`
--> src/tools/rls/src/server/mod.rs:185:21
|
173 | fn dispatch_message(&mut self, msg: &RawMessage) -> Result<(), jsonrpc::Error> {
| ----------- help: add explicit lifetime `'static` to the type of `msg`: `&'static server::message::RawMessage`
...
185 | <$n_action as LSPNotification>::METHOD => {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ lifetime `'static` required
...
259 | / match_action!(
260 | | msg.method;
261 | | notifications:
262 | | notifications::Initialized,
... |
287 | | requests::CodeLensRequest;
288 | | );
| |__________- in this macro invocation
Diffstat (limited to 'lang/rust-nightly')
-rw-r--r-- | lang/rust-nightly/files/patch-rls-nightly | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/lang/rust-nightly/files/patch-rls-nightly b/lang/rust-nightly/files/patch-rls-nightly new file mode 100644 index 000000000000..c51ab3b7d6b7 --- /dev/null +++ b/lang/rust-nightly/files/patch-rls-nightly @@ -0,0 +1,28 @@ +https://github.com/rust-lang/rls/commit/085e9266e333 + +--- src/tools/rls/src/server/mod.rs.orig 2019-01-02 15:11:46 UTC ++++ src/tools/rls/src/server/mod.rs +@@ -170,7 +170,7 @@ impl<O: Output> LsService<O> { + } + } + +- fn dispatch_message(&mut self, msg: &RawMessage) -> Result<(), jsonrpc::Error> { ++ fn dispatch_message(&mut self, msg: RawMessage) -> Result<(), jsonrpc::Error> { + macro_rules! match_action { + ( + $method: expr; +@@ -334,9 +334,12 @@ impl<O: Output> LsService<O> { + } + } + +- if let Err(e) = self.dispatch_message(&raw_message) { ++ // Workaround https://github.com/rust-lang/rust/pull/55937 by moving ++ // raw_message instead of borrowing. ++ let id = raw_message.id.clone(); ++ if let Err(e) = self.dispatch_message(raw_message) { + error!("dispatch error: {:?}, message: `{}`", e, msg_string); +- self.output.failure(raw_message.id, e); ++ self.output.failure(id, e); + return ServerStateChange::Break { exit_code: 101 }; + } + |