Now that we have function return type inference (CLJS-1997), we can see that functions like namespace return strings. Additionally, we can easily make it so that expressions involving str are inferred as returning strings. With those two in place, with a mild extension to CLJS-2314, we can eliminate unnecessary string coercions in str macro expansions where arguments are inferred to be strings.
This leads to performance gains which are akin to checked-if elimination (but perhaps even greater):
Yields these speedups under :advanced
This could be great for UIs that are heavy in string-concatenation, as well as for the self-hosted compiler.