Fixes #44. This is the "some more exotic approach" alluded to at the end there.
This changes the library API as follows:
type Weather = Sum.Member<'Sun'> | Sum.Member<'Rain', number>
const Weather = Sum.create<Weather>()
// Before
Weather.mk.Sun()
Weather.mk.Rain(123)
// After
Weather.mk.Sun // <- no function call!
Weather.mk.Rain(123)
Fixes #44. This is the "some more exotic approach" alluded to at the end there.
This changes the library API as follows: