Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-11374] crash in libswiftCore.dylib`swift::gatherWrittenGenericArgs: #53775

Closed
swift-ci opened this issue Aug 25, 2019 · 3 comments
Closed
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. 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

Comments

@swift-ci
Copy link
Collaborator

Previous ID SR-11374
Radar rdar://problem/54775582
Original Reporter miku1958 (JIRA User)
Type Bug
Status Resolved
Resolution Done

Attachment: Download

Environment

Xcode 10 and Xcode 11 beta6 all have this issue

Additional Detail from JIRA
Votes 0
Component/s
Labels Bug, RunTimeCrash, Runtime
Assignee None
Priority Medium

md5: 1136ea0efdd0cba4ea7dc556fa2a083c

Issue Description:

I try to write code like this:

extension UIView

{ class _Delegate<View> where View: UIView { }

}

extension UITextView

{ class Delegate: UIView._Delegate1<UITextView> { }

}

and it work fine when these two extension in the same file,

but once I move one of them into an new file, it crash in:

type metadata accessor for UITextView.Delegate:
libswiftCore.dylib`swift::gatherWrittenGenericArgs:

when I init a UITextView.Delegate object.

You can try these code in sample Xcode project. I am not sure is it Xcode bug or swift bug

@swift-ci
Copy link
Collaborator Author

Comment by 庄黛淳华 (JIRA)

I just try something, Delegate is not necessary to declared in other Type, but it's necessary to declared the _Delegate in other Type and using Generics

@belkadan
Copy link
Contributor

Reproduced in Xcode 11b6 compiling for the simulator. Looks like some of the other bugs we have with generics in the runtime. Thanks for reporting!

@swift-ci create

@DougGregor
Copy link
Member

Fixed by #26936

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@AnthonyLatsis AnthonyLatsis added the crash Bug: A crash, i.e., an abnormal termination of software label Dec 12, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. 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
Projects
None yet
Development

No branches or pull requests

4 participants