__precompile__() is not resulting in precompiled code [2]


Hi there,
Just trying to precompile my first module, and I don’t seem to get any precompilation.
I have something like

module Mod1
  x = 1
  f(y::Int) = x + y

Then I have something like,

using Mod1

Now, should I have a .ji file generated from this example in Base.LOAD_CACHE_PATH[1]? There is no message stating that anything is being precompiled, and certainly no file indicating there is anything cached.

Running Julia 0.6 on Windows. Thank you.



No, include does not generate precompile files and just directly executes whatever file it is given.


Thanks, after reading the documentation, I am still not sure how to generate the precompiled files, would you please elaborate on your answer just a little more?


AFAIK putting your module in the load path (ideally as a package) and then simply using it would make it precompile.