Idle thought: you can view a type system as just an abstract interpretation of code. `x = 1` can be abstracted as assuming that x is a number, then checking that numbers are appropriate wherever x is used.
Wilfred Hughes
1 Comment
Therefore a type checker simply validates a set of properties.
The hard question here: what properties should the checker consider? Primitive types? Generics? Effects? Taint tracking? Pre/postconditions?
What's the biggest bang for buck? Which is hardest to teach?
I keep thinking about the parallels between type checkers and abstract interpretation.
E.g. abstract interpretation saying "this is one of two values, but I don't know which" feels very much like type checking a boolean.
Have any tools taken advantage of this?
Shower thought: using a tool like cargo-semver, could you build a package registry where the uploader never chooses the version number?
E.g. your last release was 5.2025-09-13 and you've just changed a type, so today's release is 6.2025-11-05.
Wilfred Hughes
Shared words: thought, type, just, number
Score: 59.8
Just added an exciting new code analysis feature to Helpful: view callees.
This analyses the source code, understands macros and special forms, and gives a handy link to every function used!