-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Closed
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.code coverageArea → source tooling: code coverageArea → source tooling: code coveragecompilerThe Swift compiler itselfThe Swift compiler itselfcrashBug: A crash, i.e., an abnormal termination of softwareBug: A crash, i.e., an abnormal termination of software
Description
| Previous ID | SR-9654 |
| Radar | rdar://problem/47254122 |
| Original Reporter | broadway_lamb (JIRA User) |
| Type | Bug |
| Status | Resolved |
| Resolution | Done |
Environment
5.0-DEVELOPMENT-SNAPSHOT-2019-01-13-a
Apple Swift version 5.0-dev (LLVM ed64f75263, Clang e5012f3421, Swift 5a827a9)
Target: x86_64-apple-darwin18.2.0
Additional Detail from JIRA
| Votes | 0 |
| Component/s | Compiler |
| Labels | Bug, CodeCoverage, CompilerCrash |
| Assignee | @vedantk |
| Priority | Medium |
md5: aaa569abe2db3ea87736204ac2ff957c
Issue Description:
This code crashes the compiler when code coverage is enabled:
struct S {
subscript(i: Int, autoclosure: @autoclosure () -> Int) -> Int {
get {
return 0
}
set {
}
}
}I am using the latest (5.0-DEVELOPMENT-SNAPSHOT-2019-01-13-a) snapshot.
The SPM project to reproduce the issue: https://github.com/broadwaylamb/CompilerCrasherAutoclosureSubscript
Run:
$ swift build
$ swift test --enable-code-coverage--enable-code-coverage is important.
Metadata
Metadata
Assignees
Labels
bugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.code coverageArea → source tooling: code coverageArea → source tooling: code coveragecompilerThe Swift compiler itselfThe Swift compiler itselfcrashBug: A crash, i.e., an abnormal termination of softwareBug: A crash, i.e., an abnormal termination of software