Why are most S-Expression languages dynamically typed?

后端 未结 3 791
梦如初夏
梦如初夏 2021-02-01 17:37

How come most Lisps and Schemes are dynamically typed? Does static typing not mix with some of their common features?

3条回答
  •  佛祖请我去吃肉
    2021-02-01 18:12

    Typing and s-expressions can be made to work together, see typed scheme.

    Partly it is a historical coincidence that s-expression languages are dynamically typed. These languages tend to rely more heavily on macros, and the ease of parsing and pattern-matching on s-expressions makes macro processing much easier. Most research on sophisticated macros happens in s-expression languages.

    Typed Hygienic Macros are hard.

提交回复
热议问题