This is an automated email from the ASF dual-hosted git repository.
jiayuliu pushed a commit to branch use-rust-165
in repository https://gitbox.apache.org/repos/asf/thrift.git
The following commit(s) were added to refs/heads/use-rust-165 by this push:
new b9abd4e44 fix more lint
b9abd4e44 is described below
commit b9abd4e4489ed50a6893d4900bc934e31ffb1aa0
Author: Jiayu Liu <[email protected]>
AuthorDate: Tue Nov 7 13:05:04 2023 +0800
fix more lint
---
test/rs/src/bin/test_server.rs | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/test/rs/src/bin/test_server.rs b/test/rs/src/bin/test_server.rs
index 3e622d550..38d4b6138 100644
--- a/test/rs/src/bin/test_server.rs
+++ b/test/rs/src/bin/test_server.rs
@@ -81,7 +81,7 @@ fn run() -> thrift::Result<()> {
let (i_transport_factory, o_transport_factory): (
Box<dyn TReadTransportFactory>,
Box<dyn TWriteTransportFactory>,
- ) = match &*transport {
+ ) = match transport {
"buffered" => (
Box::new(TBufferedReadTransportFactory::new()),
Box::new(TBufferedWriteTransportFactory::new()),
@@ -98,7 +98,7 @@ fn run() -> thrift::Result<()> {
let (i_protocol_factory, o_protocol_factory): (
Box<dyn TInputProtocolFactory>,
Box<dyn TOutputProtocolFactory>,
- ) = match &*protocol {
+ ) = match protocol {
"binary" | "multi" | "multi:binary" => (
Box::new(TBinaryInputProtocolFactory::new()),
Box::new(TBinaryOutputProtocolFactory::new()),
@@ -114,7 +114,7 @@ fn run() -> thrift::Result<()> {
let test_processor =
ThriftTestSyncProcessor::new(ThriftTestSyncHandlerImpl {});
- match &*server_type {
+ match server_type {
"simple" | "thread-pool" => {
if protocol == "multi" || protocol == "multic" {
let second_service_processor =
@@ -334,7 +334,7 @@ impl ThriftTestSyncHandler for ThriftTestSyncHandlerImpl {
fn handle_test_exception(&self, arg: String) -> thrift::Result<()> {
info!("testException({})", arg);
- match &*arg {
+ match arg {
"Xception" => Err((Xception {
error_code: Some(1001),
message: Some(arg),
@@ -354,7 +354,7 @@ impl ThriftTestSyncHandler for ThriftTestSyncHandlerImpl {
// else:
// do not throw anything and return Xtruct with string_thing = arg1
fn handle_test_multi_exception(&self, arg0: String, arg1: String) ->
thrift::Result<Xtruct> {
- match &*arg0 {
+ match arg0 {
"Xception" => Err((Xception {
error_code: Some(1001),
message: Some("This is an Xception".to_owned()),