by phronmophobic · 4y ago · 0 comments
Fair point, I tried to word that statistic accurately without being too verbose.
> I'd be interested in an analysis in what percentage of Clojure functions are truly referentially transparent, but that's difficult (if not impossible) to determine statically.
Absolutely, I'm not sure it's possible or even practical to measure functional purity in an absolute sense, but there's definitely room for improvement:
- measure Java Interop
- measure usage of mutation functions (eg. swap!, set!, binding, send, vswap!, alter, etc)
- measure (def ^:dynamic *my-var*) usages
My intuition is that the numbers wouldn't change that much, but I'd rather have the data than guess.
No comments yet.