S1905 : remove unnecessary cast when the cast is required

Yes. Factory methods would help here, or implicit conversions. @VeryPaul provided a simplified example and there is probably more to the type.

Result is a discriminated union and C# lacks support for this. There are several coding pattern in use today (see the large list of nuget packages), but nothing in the language itself.

There are several proposals discussed by the language team to add one or more forms of union types to C#.