Convert scm/mononoke/sshrelay to Rust 2018

Summary:
Rust 2018 updates to:
  //scm/mononoke/sshrelay:sshrelay
  //scm/mononoke/sshrelay:sshrelay-unittest

Reviewed By: kulshrax

Differential Revision: D15466983

fbshipit-source-id: 065184fda82ecd338f0e9c7eddd49f528124cbfe
This commit is contained in:
Jeremy Fitzhardinge 2019-05-23 00:25:22 -07:00 committed by Facebook Github Bot
parent 04b62534a7
commit 3c5287e16d

View File

@ -10,7 +10,7 @@ extern crate futures_ext;
#[macro_use]
extern crate maplit;
extern crate netstring;
extern crate serde;
#[macro_use]
extern crate serde_derive;
extern crate serde_json;
@ -274,8 +274,8 @@ mod test {
use bytes::{BufMut, BytesMut};
use tokio_io::codec::{Decoder, Encoder};
use super::*;
use super::SshStream::*;
use super::*;
trait ToBytes: AsRef<[u8]> {
fn bytes(&self) -> Bytes {
@ -283,11 +283,7 @@ mod test {
}
}
impl<T> ToBytes for T
where
T: AsRef<[u8]>,
{
}
impl<T> ToBytes for T where T: AsRef<[u8]> {}
#[test]
fn encode_simple() {