Atlassian uses cookies to improve your browsing experience, perform analytics and research, and conduct advertising. Accept all cookies to indicate that you agree to our use of cookies on your device. Atlassian cookies and tracking notice, (opens new window)
Unroll (list ...) constructs to List ctor calls
Key details
Description
For small (list arg1 arg2 arg3) constructs, have the macro expand to code that directly uses the List ctor.
Here is an example of the perf benefit in the case of 2 arguments:
produces
While
produces
Perhaps this could be done for any number of list arguments, or, if perf becomes an issue for large numbers of arguments maybe it could be done only up to a certain size. (Maybe CLJS-910 factors in on older JavaScriptCore instances.)
For small
(list arg1 arg2 arg3)
constructs, have the macro expand to code that directly uses the List ctor.Here is an example of the perf benefit in the case of 2 arguments:
produces
While
produces
Perhaps this could be done for any number of
list
arguments, or, if perf becomes an issue for large numbers of arguments maybe it could be done only up to a certain size. (Maybe CLJS-910 factors in on older JavaScriptCore instances.)CLJS-1617 is relevant.