Hacker News new | past | comments | ask | show | jobs | submit login

"we can use type inference"

Technically you cannot use type inference in Common Lisp, only in a subset of the language. This is not hard to prove: you can embed a language for which general type inference is impossible (i.e. for which some expressions must have explicit type annotations), like System F, in Common Lisp. One of my complaints about Common Lisp is that the type system is really annoying when you have complex types.




> One of my complaints...

Then build a language and type system atop, like with Coalton [0]. Lisp is for language building. Even Hindley-Milner was first implemented atop Lisp in 1973 [1].

[0] https://github.com/stylewarning/coalton

[1] http://www-public.imtbs-tsp.eu/~gibson/Teaching/CSC4504/Read...


Type inference isn't all-or-nothing. If you can infer even one type in one block of code, you can generate more efficient code.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: