230V
✅ a class implementing a generic interface with more than one interface as one generic type argument
Oh, this works
...but I really wish the <T> wouldn't need to be here, I'll need to validate that T == member return type (I won't, it will be a default one, but I will need to construct a generic type with e.g.
int
as a type arg 😔) 33 replies
✅ a class implementing a generic interface with more than one interface as one generic type argument
There's just no way without some feature like extensions or something that would let me say "whatever implements I1 and I2 is X, and I have class C : IConverter<X>"
33 replies
✅ a class implementing a generic interface with more than one interface as one generic type argument
if there isn't a ConverterAttribute specified, I'll search in a list of types for a Converter<T> implementation that can be used - I need to get the T from it and check if T is compatible with the type that will be (de)serialized (this check differs slightly between reference types and value types)
33 replies
✅ a class implementing a generic interface with more than one interface as one generic type argument
yeah, I see that using Type.GenericTypeArguments produces
IL2065 Value passed to implicit 'this' parameter of method 'System.Type.GetInterface(String)' can not be statically determined and may not meet 'DynamicallyAccessedMembersAttribute' requirements.
no matter what33 replies