Fork me on GitHub
#boot
<
2018-01-05
>
zalky22:01:44

Hi all, when building a project using aot compilation, I've seen two approaches: 1. (aot :namespace #{'project.core} 2. (aot :all) Why would you use :all? My interpretation would be that by compiling the root namespace, all reachable namespaces required for the project to execute would also be compiled ahead of time (assuming we don't need unreachable namespaces). Am I misinterpreting something?

zalky22:01:48

Is :all only required if you want unreachable namespaces to be compiled as well?

seancorfield23:01:32

@zalky There's quite a lot of code out there that may require namespaces at runtime, so they wouldn't appear to be "reachable", or you may be dealing with a library that has several independent namespaces that users might require.

seancorfield23:01:00

(However, you should pretty much never AOT compile a library -- it can cause a lot of pain for your users)

seancorfield23:01:27

And, in general, I would recommend avoiding AOT compilation altogether. You don't need it.