Extend support of sum types represented by record with a discriminator field to polymorphic variants.
Extend support of sum types represented by record with a discriminator field to polymorphic variants.

sbriais/gen_js_api,LexiFi/gen_js_api,LexiFi/gen_js_api,alainfrisch/gen_js_api