I had an instance where two properties both had to of "number" and I used one instead of another on an accident. Nothing complained and it took a while to debug these.
I wonder if it is possible to extend basic types to make sure that when I try to assign, for example, the value of type Age to a variable with type Score (both being numbers tired)?
EDIT: Sorry for the original question not having a code sample. Nurbol Alpysbayev correctly interpreted my question and his code sample indeed represents what I wanted to see happening:
type Score = number;
type Age = number;
let score: Score = 999;
let age: Age = 45;
score = age; // I want to have this line to throw an error