Hacker News new | ask | show | jobs
by mrkeen 807 days ago
> I don’t want to infer types from my code. I’d rather infer the code from the types.

I use type inference for this: the compiler looks at the existing types and then infers the type of the code I haven't yet written and tells me. I then write code based on the type given to me by the compiler.