Skip to content

Commit 4ff6cda

Browse files
committed
Add module interface printing test with non-trivial pattern binding initializer
A stored property can be part of a pattern binding entry whose pattern declares multiple bindings with a single initializer, for example: struct S { let (x, y) = (0, 0) } Make sure these round-trip correctly.
1 parent 7b967a8 commit 4ff6cda

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test/ModuleInterface/stored-properties.swift

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ public struct BagOfVariables {
8383
// COMMON: public let a: Swift.Int = 0
8484
public let a: Int = 0
8585

86+
// COMMON: public let (x, y): (Swift.Int, Swift.Int) = (0, 0)
87+
public let (x, y) = (0, 0)
88+
8689
// COMMON: public var b: Swift.Bool = false
8790
public var b: Bool = false
8891

0 commit comments

Comments
 (0)