apple / swift-nio-transport-services

Extensions for SwiftNIO to support Apple platforms as first-class citizens.
https://swiftpackageindex.com/apple/swift-nio-transport-services/main/documentation/niotransportservices
Apache License 2.0
286 stars 74 forks source link

NIOFilterEmptyWritesHandler isn't guarded by `if #canImport(Network)` #110

Open glbrntt opened 3 years ago

glbrntt commented 3 years ago

All of the code in NIOTS should be guarded by if #canImport(Network). However NIOFilterEmptyWritesHandler isn't. Since its intended use is to work around a bug in Network framework, it's only helpful when Network framework is available anyway.

We can't add the check now as it would break API, but we should consider adding the missing compilation check for the next major version of NIOTS.

weissi commented 3 years ago

The bug is fixed too, so another option is to remove it entirely :)