This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-01-05
Channels
- # admin-announcements (1)
- # architecture (29)
- # beginners (244)
- # boot (5)
- # cider (2)
- # clara (8)
- # cljs-dev (58)
- # clojure (93)
- # clojure-australia (1)
- # clojure-dusseldorf (4)
- # clojure-france (1)
- # clojure-greece (16)
- # clojure-italy (9)
- # clojure-norway (1)
- # clojure-romania (1)
- # clojure-serbia (3)
- # clojure-spec (68)
- # clojure-uk (103)
- # clojurescript (41)
- # code-reviews (4)
- # community-development (4)
- # cursive (11)
- # data-science (2)
- # datascript (6)
- # defnpodcast (4)
- # docs (21)
- # duct (4)
- # emacs (118)
- # fulcro (120)
- # graphql (1)
- # jobs (1)
- # jobs-discuss (43)
- # leiningen (12)
- # off-topic (39)
- # onyx (11)
- # parinfer (13)
- # perun (1)
- # re-frame (2)
- # shadow-cljs (4)
- # spacemacs (5)
- # unrepl (6)
- # yada (1)
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?
@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.
(However, you should pretty much never AOT compile a library -- it can cause a lot of pain for your users)
And, in general, I would recommend avoiding AOT compilation altogether. You don't need it.