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
_ =pair[0] // expected-error {{tuple type '(Int, Int)' element cannot be accessed using subscript; did you mean to use '.' to access element?}} {{11-14=.0}}
682
+
_ =pair["strting"] // expected-error {{tuple type '(Int, Int)' element cannot be accessed using subscript}} {{none}}
683
+
_ =pair[-1] // expected-error {{tuple type '(Int, Int)' element cannot be accessed using subscript}} {{none}}
684
+
_ =pair[1,1] // expected-error {{tuple type '(Int, Int)' element cannot be accessed using subscript}} {{none}}
685
+
_ =void[0] // expected-error {{value of type 'Void' has no subscripts}}
686
+
687
+
_ =alias[0] // expected-error {{tuple type 'Pair' (aka '(Int, Int)') element cannot be accessed using subscript; did you mean to use '.' to access element?}} {{12-15=.0}}
688
+
_ =alias["strting"] // expected-error {{tuple type 'Pair' (aka '(Int, Int)') element cannot be accessed using subscript}} {{none}}
689
+
_ =alias[-1] // expected-error {{tuple type 'Pair' (aka '(Int, Int)') element cannot be accessed using subscript}} {{none}}
690
+
_ =alias[1,1] // expected-error {{tuple type 'Pair' (aka '(Int, Int)') element cannot be accessed using subscript}} {{none}}
0 commit comments