@@ -121,14 +121,18 @@ print("\(repr(s))")
121121// CHECK-LABEL: (expecting third reallocation)
122122print ( " (expecting third reallocation) " )
123123
124- // CHECK-NEXT: String(Native(owner: @[[storage3:[x0-9a-f]+]], count: 72, capacity: 135))
125- // CHECK-NOT: @[[storage2]],
124+ // FIXME: Now that test behavior depends on result of malloc_size, we should
125+ // rewrite this test for larger allocations. For now, disable the hard-coded
126+ // checks.
127+
128+ // xCHECK-NEXT: String(Native(owner: @[[storage3:[x0-9a-f]+]], count: 72, capacity: 135))
129+ // xCHECK-NOT: @[[storage2]],
126130s += " 1234567890123456 "
127131print ( " \( repr ( s) ) " )
128132
129133var s1 = s
130134
131- // CHECK -NEXT: String(Native(owner: @[[storage3]], count: 72, capacity: 135))
135+ // xCHECK -NEXT: String(Native(owner: @[[storage3]], count: 72, capacity: 135))
132136print ( " \( repr ( s1) ) " )
133137
134138/// The use of later buffer capacity by another string forces
@@ -137,19 +141,19 @@ print("\(repr(s1))")
137141// CHECK-LABEL: (expect copy to trigger reallocation without growth)
138142print ( " (expect copy to trigger reallocation without growth) " )
139143
140- // CHECK-NEXT: String(Native(owner: @[[storage4:[x0-9a-f]+]], count: 73, capacity: 87)) = "{{.*}}X"
144+ // CHECK-NEXT: String(Native(owner: @[[storage4:[x0-9a-f]+]], count: 73, capacity: 87)) = "{{.*}}X"
141145// CHECK-NOT: @[[storage3]],
142146s1 += " X "
143147print ( " \( repr ( s1) ) " )
144148
145149/// The original copy is left unchanged
146150
147- // CHECK -NEXT: String(Native(owner: @[[storage3]], count: 72, capacity: 135))
151+ // xCHECK -NEXT: String(Native(owner: @[[storage3]], count: 72, capacity: 135))
148152print ( " \( repr ( s) ) " )
149153
150154/// Appending to an empty string re-uses the RHS
151155
152- // CHECK -NEXT: @[[storage3]],
156+ // xCHECK -NEXT: @[[storage3]],
153157var s2 = String ( )
154158s2 += s
155159print ( " \( repr ( s2) ) " )
0 commit comments