Repository navigation
Release v7.32.0
Summary
Enum JSON converters now work in NativeAOT applications. The TypeDiscovery source generator creates the converters for the enums each assembly declares, so EnumConverterFactory no longer needs run-time generic instantiation under AOT. Applications that support dynamic code behave as before.
Added
ICanCreateEnumConverters: generated type discovery providers implement it to createEnumConverter<TEnum>for the enums their assembly declares. Hand-written providers can implement it to cover enums from assemblies built without the generator (#1237)
Fixed
EnumConverterFactoryno longer throwsNotSupportedException("EnumConverter1[...] is missing native code or metadata") under NativeAOT for enums declared in assemblies compiled with the TypeDiscovery generator. Assemblies must be rebuilt with this version. For enums from other assemblies, addnew EnumConverter()toJsonSerializerOptions.Converters` (#1237)