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/property_wrappers.swift
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -217,7 +217,7 @@ struct BadCombinations {
217
217
218
218
structMultipleWrappers{
219
219
@Wrapper(stored:17)
220
-
@WrapperWithInitialValue // expected-error{{extra argument 'wrappedValue' in call}} expected-error{{multiple property wrappers are not supported}}
220
+
@WrapperWithInitialValue // expected-error{{extra argument 'wrappedValue' in call}}
221
221
varx:Int=17
222
222
223
223
@WrapperWithInitialValue // expected-error 2{{property wrapper can only apply to a single variable}}
@@ -959,11 +959,11 @@ struct WrapperE<Value> {
959
959
}
960
960
961
961
structTestComposition{
962
-
@WrapperA@WrapperB@WrapperCvarp1:Int? // expected-error{{multiple property wrappers are not supported}}
963
-
@WrapperA@WrapperB@WrapperCvarp2="Hello" // expected-error{{multiple property wrappers are not supported}}
964
-
@WrapperD<WrapperE,Int,String>@WrapperEvarp3:Int? // expected-error{{multiple property wrappers are not supported}}
965
-
@WrapperD<WrapperC,Int,String>@WrapperCvarp4:Int? // expected-error{{multiple property wrappers are not supported}}
966
-
@WrapperD<WrapperC,Int,String>@WrapperEvarp5:Int // expected-error{{property type 'Int' does not match that of the 'wrappedValue' property of its wrapper type 'WrapperD<WrapperC, Int, String>'}} // expected-error{{multiple property wrappers are not supported}}
962
+
@WrapperA@WrapperB@WrapperCvarp1:Int?
963
+
@WrapperA@WrapperB@WrapperCvarp2="Hello"
964
+
@WrapperD<WrapperE,Int,String>@WrapperEvarp3:Int?
965
+
@WrapperD<WrapperC,Int,String>@WrapperCvarp4:Int?
966
+
@WrapperD<WrapperC,Int,String>@WrapperEvarp5:Int // expected-error{{property type 'Int' does not match that of the 'wrappedValue' property of its wrapper type 'WrapperD<WrapperC, Int, String>'}}
967
967
968
968
func triggerErrors(d:Double){
969
969
p1 = d // expected-error{{cannot assign value of type 'Double' to type 'Int?'}}
0 commit comments