Monday, September 28, 2015

Multitype has gone!

Version 0.0.3 of the outline doc ( has been updated to remove Multitype and replace it with Empty weirdness, based on the fact that Empty is at the bottom of the isA hierarchy, so Empty isA X for any X.

  • [] is a List Empty, so can be used where any List X is required;
  • Option.none is an Option Empty, so can be used where any Option X is required.
  • An explicit closure, { ... }, has type Any=>Empty, and so isA X=>Y for any X, Y.
We've drifted a bit towards dynamic typing, but all is now very straightforward.

No comments:

Post a Comment