Skip to content

Commit d1d9fd1

Browse files
authored
Merge pull request #71107 from kavon/test-coverage-computedproperty
test: ~Copyable and computed properties
2 parents 446ef9c + 34b348e commit d1d9fd1

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/SILOptimizer/moveonly_correct.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,14 @@ struct VM: ~Copyable {
1313
mutating func run() {
1414
env.constants
1515
}
16+
}
17+
18+
// rdar://109232806
19+
public protocol P_109232806 {}
20+
public struct M_109232806: ~Copyable {
21+
var x: P_109232806? = nil
22+
var y: Int { 0 }
23+
}
24+
public func test_109232806(m: borrowing M_109232806) {
25+
_ = m.y
1626
}

0 commit comments

Comments
 (0)