Date: Thu, 3 Jan 2019 03:49:57 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r489131 - head/lang/rust-nightly/files Message-ID: <201901030349.x033nvZH039802@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Thu Jan 3 03:49:57 2019 New Revision: 489131 URL: https://svnweb.freebsd.org/changeset/ports/489131 Log: 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 Added: head/lang/rust-nightly/files/patch-rls-nightly (contents, props changed) Added: head/lang/rust-nightly/files/patch-rls-nightly ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lang/rust-nightly/files/patch-rls-nightly Thu Jan 3 03:49:57 2019 (r489131) @@ -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 }; + } +
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201901030349.x033nvZH039802>