45 references to InvalidCastException
Crossgen2Tasks (1)
Microsoft.AspNetCore.Mvc.Core.TestCommon (1)
Microsoft.CodeAnalysis.LanguageServer.Protocol (12)
Protocol\SumType.cs (12)
90public static explicit operator T1(SumType<T1, T2> sum) => sum.Value is T1 tVal ? tVal : throw new InvalidCastException();
97public static explicit operator T2(SumType<T1, T2> sum) => sum.Value is T2 tVal ? tVal : throw new InvalidCastException();
330throw new InvalidCastException();
338public static explicit operator T1(SumType<T1, T2, T3> sum) => sum.Value is T1 tVal ? tVal : throw new InvalidCastException();
345public static explicit operator T2(SumType<T1, T2, T3> sum) => sum.Value is T2 tVal ? tVal : throw new InvalidCastException();
352public static explicit operator T3(SumType<T1, T2, T3> sum) => sum.Value is T3 tVal ? tVal : throw new InvalidCastException();
652throw new InvalidCastException();
676throw new InvalidCastException();
684public static explicit operator T1(SumType<T1, T2, T3, T4> sum) => sum.Value is T1 tVal ? tVal : throw new InvalidCastException();
691public static explicit operator T2(SumType<T1, T2, T3, T4> sum) => sum.Value is T2 tVal ? tVal : throw new InvalidCastException();
698public static explicit operator T3(SumType<T1, T2, T3, T4> sum) => sum.Value is T3 tVal ? tVal : throw new InvalidCastException();
705public static explicit operator T4(SumType<T1, T2, T3, T4> sum) => sum.Value is T4 tVal ? tVal : throw new InvalidCastException();
Microsoft.DotNet.XUnitAssert.Tests (17)
Microsoft.Extensions.Http.Resilience.Tests (3)
Microsoft.VisualBasic.Core (1)
System.Data.Odbc (1)
System.Linq.Expressions (2)
System.Private.CoreLib (2)
System.Private.Windows.Core (4)
System.Reflection.Metadata (1)