-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Labels
Milestone
Description
Version Used: 20250912.15 (d92fd99, main), Debug.
Steps to Reproduce:
using System;
class C
{
bool M(ReadOnlySpan<int> a, Span<int> b)
{
return b == a;
}
}(Target framework: net9.0)
This assert fails:
| Debug.Assert(false); |
System.InvalidOperationException: Assertion failed
at System.Diagnostics.Debug.Fail(String message, String detailMessage)
at System.Diagnostics.Debug.Assert(Boolean condition)
at Microsoft.CodeAnalysis.CSharp.NullableWalker.AsMemberOfType(TypeSymbol type, Symbol symbol)
at Microsoft.CodeAnalysis.CSharp.NullableWalker.ReInferBinaryOperator(SyntaxNode syntax, MethodSymbol method, BoundExpression leftOperand, BoundExpression rightOperand, TypeWithState leftUnderlyingType, TypeWithState rightUnderlyingType)