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-14479] Assertion failure for cursor info on variable with protocol type #56835

Closed
ahoppen opened this issue Apr 13, 2021 · 2 comments
Closed
Assignees
Labels
bug A deviation from expected or documented behavior. Also: expected but undesirable behavior. found by stress tester Flag: An issue found by the SourceKit stress tester

Comments

@ahoppen
Copy link
Contributor

ahoppen commented Apr 13, 2021

Previous ID SR-14479
Radar rdar://problem/76580851
Original Reporter @ahoppen
Type Bug
Status Closed
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s Source Tooling
Labels Bug, FoundByStressTester
Assignee @ahoppen
Priority Medium

md5: 09520ef541eec7485399d627a8500357

Issue Description:

Save the following as ~/Desktop/test.swift

protocol Foo {
    var myVar: String { get }
}

func foo(error: Foo) {
    _ = error.myVar
} 

Run:

sourcekitd-test -req=cursor -pos=6:16 ~/Desktop/test.swift -- -c ~/Desktop/test.swift

Crashes with

Assertion failed: (T->mayHaveMembers()), function TypeTransformContext, file /Users/alex/swift-src/swift/lib/AST/ASTPrinter.cpp, line 270.
PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace.
@ahoppen
Copy link
Contributor Author

ahoppen commented Apr 13, 2021

@swift-ci create

@ahoppen
Copy link
Contributor Author

ahoppen commented Apr 15, 2021

Fixed in #36880

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 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. found by stress tester Flag: An issue found by the SourceKit stress tester
Projects
None yet
Development

No branches or pull requests

1 participant