[SR-4611] Runtime crash with nested type used as superclass generic argument #47188
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
crash
Bug: A crash, i.e., an abnormal termination of software
run-time crash
Bug → crash: Swift code crashed during execution
runtime
The Swift Runtime
Additional Detail from JIRA
md5: cae105004f0afe8b0cad98e9ecd852b9
duplicates:
relates to:
Issue Description:
The following code compiles without warning but when run crashes instantiating Subclass instance, prior to entering Subclass.init. Would appear to be due to having nested struct A defined within Subclass and this being used as generic parameter. Refactoring struct A so its not nested and no crash. If this is not valid to use nested type as generic parameter like this should not the compiler give an error? If it is valid code the runtime crash should be fixed.
$ swiftc --version
Apple Swift version 3.1 (swiftlang-802.0.51 clang-802.0.41)
The text was updated successfully, but these errors were encountered: