When I try to build my app with Xcode 8 beta (after converting my Swift 2.2 to Swift 3 using the built-in tool), the automatically generated Swift header (TargetName-Swift.h
) has some errors. There are 3 different errors occurring at multiple lines.
For example in this section:
SWIFT_CLASS_PROPERTY(@property (nonatomic, class, copy) NSArray<NSDictionary<NSString *, NSString *> *> * _Nonnull CANewsFilterBlacklist;)
+ (NSArray<NSDictionary<NSString *, NSString *> *> * _Nonnull)CANewsFilterBlacklist;
+ (void)setCANewsFilterBlacklist:(NSArray<NSDictionary<NSString *, NSString *> *> * _Nonnull)newValue;
Line 1:
TargetName-Swift.h:562:90: Too many arguments provided to function-like macro invocation
and
TargetName-Swift.h:562:1: Unknown type name 'SWIFT_CLASS_PROPERTY'
Line 2:
TargetName-Swift.h:563:1: Expected identifier or '('
This is the Swift-Code that belongs to the code above:
public static var CANewsFilterBlacklist:[[String:String]] {
get {
if let data = iCloudStorageStatic.object(forKey: CAUserDefaultsNewsFilterBlacklistKey) as? [[String:String]] {
return data
} else {
return [[String:String]]()
}
}
set (newValue) {
iCloudStorageStatic.set(newValue, forKey: CAUserDefaultsNewsFilterBlacklistKey)
}
}
I have no idea, what is wrong with my Swift-Code? Xcode does not show any errors in the Swift code. It just generates the corrupt Swift-Header.
Is this a bug in Xcode 8 (in Xcode 7, everything worked as expected)?