emqx / CocoaMQTT

MQTT 5.0 client library for iOS and macOS written in Swift
https://www.emqx.com/en
Other
1.59k stars 418 forks source link

Fix compile error "Enum cases with associated values cannot be marked potentially unavailable with '@available'" #391

Closed KarinBerg closed 2 years ago

KarinBerg commented 2 years ago

As far I understood the problem we have two possible solutions:

Last one is not want we want to do for this library. First one could be achieved with "Nested Enums" (At least I think so). This is want I did in this pull request. Want do you think? Feedback highly welcome. 🤗

For info about "Nested Enums" see https://developerinsider.co/advanced-enum-enumerations-by-example-swift-programming-language/

leeway1208 commented 2 years ago

so cool

klauslanza commented 2 years ago

I think a new release of the library could help out people using Cocoapod integration and missing out on the latest commits to master... Are there any plan on this?