Re:A decade of developing a programming language
by nicoburns on Tuesday November 14, 2023 @07:27PM
(#38271790)
Would type-inference also "screw up the semantics"? My understanding is that this generally operates via some kind of constraints solving.
[ Parent
| on HN ]
Re:A decade of developing a programming language
by orthoxerox on Wednesday November 15, 2023 @03:19AM
(#38274462)
Depends on how much type inference you want.
If you want ML-style total type inference when you expect the compiler to deduce the parameter and the return types of your functions, then yes.
Local variable type inference isn't hard at all, unless you want to do stuff like Rust: declare a variable without an initial value and infer its type from the first assignment downcode.