Great post on how to use union types effectively: https://robots.thoughtbot.com/modeling-with-union-types (has a lovely example of modelling a deck of cards: how do you handle suits and jokers?)
Related Posts
Difftastic has been cited in a paper!
Modernizing SMT-Based Type Error Localization https://arxiv.org/abs/2408.09034
The authors use difftastic to work out which parts of a buggy program have actually changed, a great use case :)
I'm never sure what to name my remotes in git. I tend to use 'mine' so I can add other forks later, but sometimes I use 'gh' or the traditional 'origin'.
What do others use?
@tristanC That's an option! There's often cases where you know what the user wanted though, so you can provide a sensible AST that the toolchain can handle.
For example, a malformed string literal can still be parsed a string so type checking etc can be helpful.