Hacker News new | ask | show | jobs
by LtWorf 111 days ago
It must be used in combination with a static checker to be useful.

So you can do like a = typedload.load(json_data, int) and then "a" is considered to be an int and at runtime will be an int.

Of course your static checker should prevent you from doing a + "string" later on because that would fail.