This is an automated email from the ASF dual-hosted git repository.

jensg pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/thrift.git


The following commit(s) were added to refs/heads/master by this push:
     new 4b475af  THRIFT-5084: Multiplexed processor in Swift – explicit return 
statements Client: swift Patch: Alexander Edge
4b475af is described below

commit 4b475af6943d99a21e2b79578167a4d228fe0df1
Author: Alexander Edge <[email protected]>
AuthorDate: Mon Feb 24 10:37:25 2020 +0000

    THRIFT-5084: Multiplexed processor in Swift – explicit return statements
    Client: swift
    Patch: Alexander Edge
    
    This closes #2028
---
 lib/swift/Sources/TMultiplexedProcessor.swift |  2 +-
 lib/swift/Sources/TProtocolDecorator.swift    | 28 +++++++++++++--------------
 2 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/lib/swift/Sources/TMultiplexedProcessor.swift 
b/lib/swift/Sources/TMultiplexedProcessor.swift
index 9841d3f..661d4a7 100644
--- a/lib/swift/Sources/TMultiplexedProcessor.swift
+++ b/lib/swift/Sources/TMultiplexedProcessor.swift
@@ -86,6 +86,6 @@ private final class StoredMessage: TProtocolDecorator {
   }
 
   override func readMessageBegin() throws -> (String, TMessageType, Int32) {
-    message
+    return message
   }
 }
diff --git a/lib/swift/Sources/TProtocolDecorator.swift 
b/lib/swift/Sources/TProtocolDecorator.swift
index 3f3b4a1..b1b1480 100644
--- a/lib/swift/Sources/TProtocolDecorator.swift
+++ b/lib/swift/Sources/TProtocolDecorator.swift
@@ -34,7 +34,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readMessageBegin() throws -> (String, TMessageType, Int32) {
-    try proto.readMessageBegin()
+    return try proto.readMessageBegin()
   }
 
   func readMessageEnd() throws {
@@ -42,7 +42,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readStructBegin() throws -> String {
-    try proto.readStructBegin()
+    return try proto.readStructBegin()
   }
 
   func readStructEnd() throws {
@@ -50,7 +50,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readFieldBegin() throws -> (String, TType, Int32) {
-    try proto.readFieldBegin()
+    return try proto.readFieldBegin()
   }
 
   func readFieldEnd() throws {
@@ -58,7 +58,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readMapBegin() throws -> (TType, TType, Int32) {
-    try proto.readMapBegin()
+    return try proto.readMapBegin()
   }
 
   func readMapEnd() throws {
@@ -66,7 +66,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readSetBegin() throws -> (TType, Int32) {
-    try proto.readSetBegin()
+    return try proto.readSetBegin()
   }
 
   func readSetEnd() throws {
@@ -74,7 +74,7 @@ class TProtocolDecorator: TProtocol {
   }
 
   func readListBegin() throws -> (TType, Int32) {
-    try proto.readListBegin()
+    return try proto.readListBegin()
   }
 
   func readListEnd() throws {
@@ -82,35 +82,35 @@ class TProtocolDecorator: TProtocol {
   }
 
   func read() throws -> String {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Bool {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> UInt8 {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Int16 {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Int32 {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Int64 {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Double {
-    try proto.read()
+    return try proto.read()
   }
 
   func read() throws -> Data {
-    try proto.read()
+    return try proto.read()
   }
 
   func writeMessageBegin(name: String, type messageType: TMessageType, 
sequenceID: Int32) throws {

Reply via email to