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
{{ message }}
Repository navigation
TUnit0001 rejects a generic array element inside a tuple parameter #7489
A method data source returning a tuple with an array element is rejected with TUnit0001 when the test accepts the same tuple with a generic array element. The diagnostic prevents compilation even though the source supplies an int[] and the test can infer T = int.
Expected: infer T = int and accept the compatible tuple element types. Actual: TUnit0001 rejects the row. Replacing the array element with int and the corresponding parameter element with T compiles.
Environment
.NET SDK 10.0.403, net10.0, macOS arm64, PR head 47ce168 plus its review fixes. The review fixes do not change analyzer code. Checked open and closed issues; #7463 concerns expanded trailing arguments, and #7108 concerns non-tuple source discovery. Current main 9100521 retains the generic-array validation path that only checks top-level array parameters, while its newer tuple changes address reference-tuple unwrapping.
Found while validating #7469. Please accept compatible generic array elements inside a single tuple parameter and add positive and negative analyzer regressions.
Activity
Preserve tuple conversions and reject incompatible tuple arrays (#7489)
Preserve generic array reference conversions (#7489)
Preserve nested array invariance in method data matching (#7489)
Preserve nested containing types and interface variance (#7489)
Preserve open arguments in contravariant array matching (#7489)
Reject conflicting invariant array inference (#7489)
Fix mixed variance bounds and array interface matching for #7489
Fix variant bounds and retry interface inference for #7489
Reject incompatible contravariant upper bounds for #7489
Fix tuple binding consistency and delegate variance (#7489)
Fix nested array inference bounds for #7489
Fix shared direct-array bindings and array class bounds for #7489
Reject impossible array interface bounds for #7489
fix(analyzers): reject unrelated delegate upper bounds (#7489)
Validate delegate upper-bound arguments for #7489
fix(analyzers): compare nested delegate containers (#7489)
fix(analyzers): preserve nested delegate containing identity (#7489)
fix(analyzers): reconcile joint array interface bounds (#7489)
fix(analyzers): bound search and reconcile delegate upper bounds (#7489)
docs(analyzers): explain row search budget for #7489