You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: test/decl/var/usage.swift
+9-8Lines changed: 9 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -303,14 +303,6 @@ func sr964() {
303
303
}
304
304
}
305
305
}
306
-
extensionMemberGetterClass{
307
-
varsuspiciousSetterExt:String{
308
-
get{return""}
309
-
set{
310
-
print(suspiciousSetterExt) // expected-warning {{setter argument 'newValue' was never used, but the property was accessed}} expected-note {{did you mean to use 'newValue' instead of accessing the property's current value?}} {{15-34=newValue}}
311
-
}
312
-
}
313
-
}
314
306
varnamedSuspiciousSetter:String{
315
307
get{return""}
316
308
set(parameter){
@@ -329,3 +321,12 @@ func sr964() {
329
321
}
330
322
}
331
323
}
324
+
structMemberGetterExtension{}
325
+
extensionMemberGetterExtension{
326
+
varsuspiciousSetter:String{
327
+
get{return""}
328
+
set{
329
+
print(suspiciousSetter) // expected-warning {{setter argument 'newValue' was never used, but the property was accessed}} expected-note {{did you mean to use 'newValue' instead of accessing the property's current value?}} {{13-29=newValue}}
0 commit comments