3 ms·
Siek/Taha in http://scheme2006.cs.uchicago.edu/13-siek.pdf http://scheme2006.cs.uchicago.edu/13-siek.pdf say > Common LISP [23] and Dylan [12, 37] include opt
by lispm 9y ago
Siek/Taha in http://scheme2006.cs.uchicago.edu/13-siek.pdf http://scheme2006.cs.uchicago.edu/13-siek.pdf say
> Common LISP [23] and Dylan [12, 37] include optional type annotations, but the annotations are not used for type checking, they are used to improve performance.
Actually, type annotations in Common Lisp have been mostly used for three different purposes:
* improving performance
(by choosing specialized operations
and/or removing runtime type checks/dispatching)
* improving runtime safety, plus better error messages
(by adding more and more specific runtime type checks)
* improving compile-time safety
(by compile-time warnings of type errors)
The CMUCL compiler has used optional type declarations and type annotations at compile time for some static type checking, combined with some type inference.
https://common-lisp.net/project/cmucl/doc/cmu-user/compiler.html#sec131 https://common-lisp.net/project/cmucl/doc/cmu-user/compiler....
There are at least two forks of CMUCL (SBCL and Scieneer CL), which use this,too.
Thus CMU Common Lisp has optional static typing + a limited form of compile-time type inference/propagation/checks.
Not sure when CMUCL added this, probably in the late 80s/early 90s. It was for example published in 1992 in the paper: 'The Python compiler for CMU Common Lisp', https://www.researchgate.net/publication/221252239_Python_compiler_for_CMU_common_Lisp https://www.researchgate.net/publication/221252239_Python_co...