Skip to content

Instantly share code, notes, and snippets.

@kennetpostigo
Created June 23, 2018 00:43
Show Gist options
  • Save kennetpostigo/f8c3a071d6ed0add1d64201458a62355 to your computer and use it in GitHub Desktop.
Save kennetpostigo/f8c3a071d6ed0add1d64201458a62355 to your computer and use it in GitHub Desktop.
Reason Phantom Type Animal module
module Animal: Animal = {
type t('a) = string;
type dog;
type cat;
let makeDog = d => d;
let makeCat = c => c;
let mate = (x, y) => {j|๐ŸŒˆ $x and $y mated! ๐ŸŒˆ|j};
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment