You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create another project, then import the created xcframework at step 3.
Actually result:
In the generated *.swiftinterface file in the xcframework Modules folder. the code looks like below:
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.1 (swiftlang-1100.0.270.13 clang-1100.0.33.7)
// swift-module-flags: -target x86_64-apple-ios12.4-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name XCInitTest
import Foundation
import Swift
@_exported import XCInitTest
open class ObjectBase {
public init() @objc deinit
}
open class UntypedList : XCInitTest.ObjectBase {
public init(capacity: Swift.Int)
override public init() @objc deinit
}
open class EmptyList : XCInitTest.UntypedList {
public init()
override public init(capacity: Swift.Int) @objc deinit
}
Expected result:
The line 'override public init()' in open class UntypedList
And
The line 'public init()' in open class EmptyList
should not be generated, because the ObjectBase has its explicit Initializers. no need Default Initializers for ObjectBase anymore.
so no need to override init() in its subclass.
The text was updated successfully, but these errors were encountered:
Attachment: Download
Environment
This issue happens since Xcode 11 GM Seed 2
Additional Detail from JIRA
md5: 4a36bee285ec81863a9a5a6cf58296af
Issue Description:
we had submitted a feedback ticket (FB7301109) since Sep, 2019. But never get response from Apple. we have to try report this issue on forums. swift.
issue Description:
There will be build error if use a framework which is generate with below code
import Foundation
open class ObjectBase {
public init()
{ }
}
open class UntypedList : ObjectBase {
public init(capacity:Int)
{ }
}
open class EmptyList : UntypedList {
public init() {
super.init(capacity: 5)
}
}
List the reproduce steps:
Use above sample code to create a framework
Archive it.
xcodebuild -create-xcframework to create xcframework. (Refer page: https://appspector.com/blog/xcframeworks )
Create another project, then import the created xcframework at step 3.
Actually result:
In the generated *.swiftinterface file in the xcframework Modules folder. the code looks like below:
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.1 (swiftlang-1100.0.270.13 clang-1100.0.33.7)
// swift-module-flags: -target x86_64-apple-ios12.4-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name XCInitTest
import Foundation
import Swift
@_exported import XCInitTest
open class ObjectBase {
public init()
@objc deinit
}
open class UntypedList : XCInitTest.ObjectBase {
public init(capacity: Swift.Int)
override public init()
@objc deinit
}
open class EmptyList : XCInitTest.UntypedList {
public init()
override public init(capacity: Swift.Int)
@objc deinit
}
Expected result:
The line 'override public init()' in open class UntypedList
And
The line 'public init()' in open class EmptyList
should not be generated, because the ObjectBase has its explicit Initializers. no need Default Initializers for ObjectBase anymore.
so no need to override init() in its subclass.
The text was updated successfully, but these errors were encountered: