Skip to content

Commit cdcba40

Browse files
committed
Update some tests
1 parent c3a9daa commit cdcba40

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

test/Parse/explicit_lifetime_dependence_specifiers.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,16 @@ struct BufferView : ~Escapable {
2424
self.ptr = ptr
2525
return self
2626
}
27-
init(_ ptr: UnsafeRawBufferPointer, _ a: consuming Wrapper, b: borrowing Array<Int>) -> dependsOn(a) dependsOn(b) Self {
27+
init(_ ptr: UnsafeRawBufferPointer, _ a: consuming Wrapper, b: borrowing Array<Int>) -> dependsOn(a) dependsOn(scoped b) Self {
2828
self.ptr = ptr
2929
return self
3030
}
31-
init(_ ptr: UnsafeRawBufferPointer, _ a: borrowing Array<Double>, b: borrowing Array<Int>, c: Double) -> dependsOn(a) dependsOn(b) Int { // expected-error{{expected Self return type for initializers with lifetime dependence specifiers}}
31+
init(_ ptr: UnsafeRawBufferPointer, _ a: borrowing Array<Double>, b: borrowing Array<Int>, c: Double) -> dependsOn(scoped a) dependsOn(b) Int { // expected-error{{expected Self return type for initializers with lifetime dependence specifiers}}
3232
self.ptr = ptr
3333
return 0
3434
}
35-
/* TODO: Enable this test once stdlib builds with NonescapableTypes support
36-
init?(_ ptr: UnsafeRawBufferPointer, _ a: borrowing Array<Int>, _ i: Int) -> dependsOn(a) Self {
35+
/* TODO: Enable this test once Optional is ~Escapable
36+
init?(_ ptr: UnsafeRawBufferPointer, _ a: borrowing Array<Int>, _ i: Int) -> dependsOn(a) Self? {
3737
if (i % 2 == 0) {
3838
self.ptr = ptr
3939
return self

0 commit comments

Comments
 (0)