// (35,12): warning CS0612: 'ValueTuple<T1, T2>' is obsolete
// static (int a, int b, int c, int d, int e, int f, int g, int h, int Item2) M103()
Diagnostic(ErrorCode.WRN_DeprecatedSymbol, "(int a, int b, int c, int d, int e, int f, int g, int h, int Item2)").WithArguments("System.ValueTuple<T1, T2>").WithLocation(35, 12),
Dim x As (a As Integer, a As String) = (b:=1, b:="hello", b:=2)
~
BC37262: Tuple member names must be unique.
BC37262: Tuple element names must be unique.
Dim x As (a As Integer, a As String) = (b:=1, b:="hello", b:=2)
~
BC37262: Tuple member names must be unique.
BC37262: Tuple element names must be unique.
Dim x As (a As Integer, a As String) = (b:=1, b:="hello", b:=2)
~
</errors>)
...
...
@@ -3923,16 +3923,16 @@ End Module
comp.AssertTheseDiagnostics(
<errors>
BC37261: Tuple member name 'Item1' is only allowed at position 1.
BC37261: Tuple element name 'Item1' is only allowed at position 1.
Dim x As (Item1 As Integer, Item1 As String) = (Item1:=1, Item1:="hello")
~~~~~
BC37261: Tuple member name 'Item1' is only allowed at position 1.
BC37261: Tuple element name 'Item1' is only allowed at position 1.
Dim x As (Item1 As Integer, Item1 As String) = (Item1:=1, Item1:="hello")
~~~~~
BC37261: Tuple member name 'Item2' is only allowed at position 2.
BC37261: Tuple element name 'Item2' is only allowed at position 2.
Dim y As (Item2 As Integer, Item2 As String) = (Item2:=1, Item2:="hello")
~~~~~
BC37261: Tuple member name 'Item2' is only allowed at position 2.
BC37261: Tuple element name 'Item2' is only allowed at position 2.
Dim y As (Item2 As Integer, Item2 As String) = (Item2:=1, Item2:="hello")
~~~~~
</errors>)
...
...
@@ -3957,13 +3957,13 @@ End Module
comp.AssertTheseDiagnostics(
<errors>
BC37261: Tuple member name 'Item10' is only allowed at position 10.
BC37261: Tuple element name 'Item10' is only allowed at position 10.
Dim x As (Item1 As Integer, Item01 As Integer, Item10 As Integer) = (Item01:=1, Item1:=2, Item10:=3)
~~~~~~
BC37261: Tuple member name 'Item1' is only allowed at position 1.
BC37261: Tuple element name 'Item1' is only allowed at position 1.
Dim x As (Item1 As Integer, Item01 As Integer, Item10 As Integer) = (Item01:=1, Item1:=2, Item10:=3)
~~~~~
BC37261: Tuple member name 'Item10' is only allowed at position 10.
BC37261: Tuple element name 'Item10' is only allowed at position 10.
Dim x As (Item1 As Integer, Item01 As Integer, Item10 As Integer) = (Item01:=1, Item1:=2, Item10:=3)
~~~~~~
</errors>)
...
...
@@ -4011,10 +4011,10 @@ End Module
comp.AssertTheseDiagnostics(
<errors>
BC37262: Tuple member names must be unique.
BC37262: Tuple element names must be unique.
Dim x As (a As Integer, a As String) = (b:=1, c:="hello", b:=2)
~
BC37262: Tuple member names must be unique.
BC37262: Tuple element names must be unique.
Dim x As (a As Integer, a As String) = (b:=1, c:="hello", b:=2)
~
</errors>)
...
...
@@ -4040,22 +4040,22 @@ End Module
comp.AssertTheseDiagnostics(
<errors>
BC37261: Tuple member name 'Item3' is only allowed at position 3.
BC37261: Tuple element name 'Item3' is only allowed at position 3.
Dim x As (Item1 As Integer, Item3 As String, Item2 As Integer, Item4 As Integer, Item5 As Integer, Item6 As Integer, Item7 As Integer, Rest As Integer) =
~~~~~
BC37261: Tuple member name 'Item2' is only allowed at position 2.
BC37261: Tuple element name 'Item2' is only allowed at position 2.
Dim x As (Item1 As Integer, Item3 As String, Item2 As Integer, Item4 As Integer, Item5 As Integer, Item6 As Integer, Item7 As Integer, Rest As Integer) =
~~~~~
BC37260: Tuple member name 'Rest' is disallowed at any position.
BC37260: Tuple element name 'Rest' is disallowed at any position.
Dim x As (Item1 As Integer, Item3 As String, Item2 As Integer, Item4 As Integer, Item5 As Integer, Item6 As Integer, Item7 As Integer, Rest As Integer) =
~~~~
BC37261: Tuple member name 'Item2' is only allowed at position 2.
BC37261: Tuple element name 'Item2' is only allowed at position 2.