Skip to content

Commit

Permalink
swift 5.9 (#141)
Browse files Browse the repository at this point in the history
  • Loading branch information
adam-fowler authored Oct 24, 2023
1 parent acab374 commit deae8ea
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "MQTT Swift 5.6",
"name": "MQTT Swift",
"dockerComposeFile": "docker-compose.yml",
"service": "app",
"workspaceFolder": "/workspace",
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: "3.3"

services:
app:
image: swift:5.8
image: swift:5.9
volumes:
- ..:/workspace
depends_on:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/api-breakage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
linux:
runs-on: ubuntu-latest
container:
image: swift:5.8
image: swift:5.9
steps:
- name: Checkout
uses: actions/checkout@v3
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,10 @@ jobs:
strategy:
matrix:
tag:
- swift:5.6
- swift:5.7
- swift:5.8
- swift:5.9
- swiftlang/swift:nightly-5.10-jammy
container:
image: ${{ matrix.tag }}
services:
Expand Down
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// swift-tools-version:5.6
// swift-tools-version:5.7

import PackageDescription

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# MQTT NIO

[![sswg:sandbox|94x20](https://img.shields.io/badge/sswg-sandbox-lightgrey.svg)](https://github.com/swift-server/sswg/blob/master/process/incubation.md#sandbox-level)
[<img src="https://img.shields.io/badge/swift-5.6_to_5.8-brightgreen.svg" alt="Swift 5.8" />](https://swift.org)
[<img src="https://img.shields.io/badge/swift-5.7-brightgreen.svg" alt="Swift 5.7" />](https://swift.org)
[<img src="https://github.com/adam-fowler/mqtt-nio/workflows/CI/badge.svg" />](https://github.com/adam-fowler/mqtt-nio/workflows/CI/badge.svg)

A Swift NIO based MQTT v3.1.1 and v5.0 client.
Expand Down
4 changes: 0 additions & 4 deletions Sources/MQTTNIO/MQTTClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,7 @@ public final class MQTTClient {
/// flag to tell is client is shutdown
private let isShutdown = ManagedAtomic(false)

#if swift(>=5.6)
typealias ShutdownCallback = @Sendable (Error?) -> Void
#else
typealias ShutdownCallback = (Error?) -> Void
#endif

/// Create MQTT client
/// - Parameters:
Expand Down
2 changes: 1 addition & 1 deletion Tests/MQTTNIOTests/MQTTNIOTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ final class MQTTNIOTests: XCTestCase {
XCTFail("Did not expect \(String(describing: requestEnd))")
}
_ = try channel.finish()
promise.succeed()
promise.succeed(())
}

// MARK: Helper variables and functions
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: "3.3"

services:
test:
image: swift:5.5
image: swift:5.9
working_dir: /mqtt-nio
volumes:
- .:/mqtt-nio
Expand Down

0 comments on commit deae8ea

Please sign in to comment.