Patchwork D8384: rust-chg: silence warning about dated coding style

login
register
mail settings
Submitter phabricator
Date April 6, 2020, 2:19 p.m.
Message ID <differential-rev-PHID-DREV-qmr55aeh2o3qjl6xqrvd-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/46032/
State Superseded
Headers show

Comments

phabricator - April 6, 2020, 2:19 p.m.
yuja created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

BRANCH
  default

REVISION DETAIL
  https://phab.mercurial-scm.org/D8384

AFFECTED FILES
  rust/chg/src/message.rs
  rust/chg/src/runcommand.rs

CHANGE DETAILS




To: yuja, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/rust/chg/src/runcommand.rs b/rust/chg/src/runcommand.rs
--- a/rust/chg/src/runcommand.rs
+++ b/rust/chg/src/runcommand.rs
@@ -37,7 +37,7 @@ 
     Finished,
 }
 
-type CommandPoll<C, H> = io::Result<(AsyncS<(Client<C>, H, i32), CommandState<C, H>>)>;
+type CommandPoll<C, H> = io::Result<AsyncS<(Client<C>, H, i32), CommandState<C, H>>>;
 
 /// Future resolves to `(exit_code, client)`.
 #[must_use = "futures do nothing unless polled"]
diff --git a/rust/chg/src/message.rs b/rust/chg/src/message.rs
--- a/rust/chg/src/message.rs
+++ b/rust/chg/src/message.rs
@@ -152,7 +152,7 @@ 
 
 fn new_parse_error<E>(error: E) -> io::Error
 where
-    E: Into<Box<error::Error + Send + Sync>>,
+    E: Into<Box<dyn error::Error + Send + Sync>>,
 {
     io::Error::new(io::ErrorKind::InvalidData, error)
 }