Make the assumptions in `driver.js` regarding the JSON encoding of sum
types explicit in `Types.hs`.