3 ms·
Julia is very lispy (and was originally designed on femtolisp), which gives it a lot of nice features including macros. Julia's macros aren't quite as flexible
by SatvikBeri 2y ago
Julia is very lispy (and was originally designed on femtolisp), which gives it a lot of nice features including macros. Julia's macros aren't quite as flexible as Common Lisp, but they're way beyond e.g. Python.
We have used these macros to save a lot of time and money (multiple developer salaries). One example is by implementing a DSL for numeric code that allowed researchers to write in Python-like syntax, but would get transformed into a DAG for longer-running jobs that could be evaluated much more efficiently + in parallel.
We could not make something nearly as performant in Python – we spent hundreds of developer hours trying, because we already had a lot of working code and were trying to make it faster/cheaper to run. Nobody wants to rewrite a large, working codebase. Yes, we tried numba, pypy, custom C extensions etc. – in the end a Julia prototype written in one week significantly outperformed all of them. Three years later we still use Julia for all our numeric code.