Hello everyone, It does seem like it is currently possible to wrap just the function declaration in an #if swift() directive like so:
#if swift(>=3.0) public func add(filter filterName: String, path: String) { #else // ERROR Expected ā}ā at end of brace statement public func addFilter(filterName: String, path: String) { #endif Is it possible Iām missing how to do this? This is particularly painful in Swift 3 given the change to move have labels on the first function parameter by default. As far as I can see it means that I am required to wrap the entire function body even if nothing else is incompatible with Swift 3. Is this just an implementation detail that will be changed? Thanks, Tyler
_______________________________________________ swift-users mailing list swift-users@swift.org https://lists.swift.org/mailman/listinfo/swift-users