I have the following definiition for a State Machine in F#:
type MyEvent = Event1 | Event2 | Event3 type MachineState<\'event when \'event:comparison>