Hacker News new | ask | show | jobs
by callumlocke 3203 days ago
You don't lose it. You use type checking like a linter, to highlight issues as you type.

If you also want to use it as an enforcer, you set it up as a pre-commit hook or a CI step or whatever you want.

The idea is not to be forced to typecheck on every little incremental build during development. Sometimes I _know_ what needs to be done to get typechecking to pass (I can see the type errors highlighted in my editor after all) but I don't want to have to fix it before running my code to see how it behaves, because maybe I'm just playing around with an idea.

There are pros and cons to typechecking and not typechecking, which is why both kinds of language exist. Annotation- stripping lets you get the best of both worlds.