Fix 5.6 compiler error (#182)

# Motivation
After my recent PR we failed to compile on 5.6 since the compiler isn't capable to infer the return type of one of the closures.

# Modification
This PR adds the closure's return type explicitly.

# Result
Compiling on 5.6 again
This commit is contained in:
Franz Busch 2023-07-28 11:11:31 +01:00 committed by GitHub
parent fbc49d892b
commit b4d9e61a6d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -185,7 +185,7 @@ final class AsyncChannelBootstrapTests: XCTestCase {
.bind(
host: "127.0.0.1",
port: 0
) { channel in
) { channel -> EventLoopFuture<NIOAsyncChannel<String, String>> in
channel.eventLoop.makeCompletedFuture {
try channel.pipeline.syncOperations.addHandler(ByteToMessageHandler(LineDelimiterCoder()))
try channel.pipeline.syncOperations.addHandler(MessageToByteHandler(LineDelimiterCoder()))