I tried searching around the group and I couldn't really find what I was 
looking for.

I'm running the following Julia version on Windows:
Julia Version 0.4.0-dev+6859
Commit 92ddae7 (2015-08-20 19:38 UTC)
Platform Info:
  System: Windows (x86_64-w64-mingw32)
  CPU: Intel(R) Core(TM) i5-4300U CPU @ 1.90GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas
  LIBM: libopenlibm
  LLVM: libLLVM-3.3

In a folder testjulia, I have two files: a.jl and test.jl

a.jl:

module a

function fun(x,y)
  return x+y
end

end


test.jl:

using a

println(a.fun(3,5))

When I run include("test.jl") after changing the directory to testjulia in 
the Julia repl, I get the following error:

ERROR: LoadError: ArgumentError: a not found in path
 in require at loading.jl:196
 in include at boot.jl:259
 in include_from_node1 at loading.jl:267
while loading C:\Users\***\Documents\testjulia\test.jl, in expression 
starting on line 1

This behavior does not occur when using Julia v0.3.  I thought 
Base.require() would also search in the current directory for a file named 
"a.jl" to search for module a and load it.

What would be the correct way to make a module and load it as in the 
example above?  Thanks!

Reply via email to