Re: [julia-users] ERROR: ArgumentError: MyTest not found in path

2015-12-09 Thread Yichao Yu
On Wed, Dec 9, 2015 at 1:52 AM, Ajith Joseph  wrote:
> I am getting started with Julia - Version 0.4.2. I am not able to load a
> module in REPL
>
> ajoseph-osx:julia_test ajoseph$ cat /Users/ajoseph/julia_test/test.jl
>
> module MyTest
>
> end
>
>
> julia> push!(LOAD_PATH, "/Users/ajoseph/julia_test")
>
> 3-element Array{ByteString,1}:
>
>
> "/Applications/Julia-0.4.2.app/Contents/Resources/julia/local/share/julia/site/v0.4"
>
>
> "/Applications/Julia-0.4.2.app/Contents/Resources/julia/share/julia/site/v0.4"
>
>  "/Users/ajoseph/julia_test"
>
>
> julia> using MyTest
>
> ERROR: ArgumentError: MyTest not found in path
>
>  in require at
> /Applications/Julia-0.4.2.app/Contents/Resources/julia/lib/julia/sys.dylib
>
>
> What am I doing wrong here?

Rename your file to match the name of the module. Even though the
module name is not tied to file names in julia, the loader still need
to be able to figure out the file to know from the module name. If the
file it find (`ModuleName/src/ModuleName.jl` or `ModuleName.jl` in
load path) doesn't define the module, you will get a warning.

>
> Thanks


[julia-users] ERROR: ArgumentError: MyTest not found in path

2015-12-09 Thread Ajith Joseph
I am getting started with Julia - Version 0.4.2. I am not able to load a 
module in REPL

ajoseph-osx:julia_test ajoseph$* cat /Users/ajoseph/julia_test/test.jl *

*module MyTest*

*end*


*julia> **push!(LOAD_PATH, "/Users/ajoseph/julia_test")*

*3-element Array{ByteString,1}:*

* 
"/Applications/Julia-0.4.2.app/Contents/Resources/julia/local/share/julia/site/v0.4"*

* 
"/Applications/Julia-0.4.2.app/Contents/Resources/julia/share/julia/site/v0.4" 
 *

* "/Users/ajoseph/julia_test"*


*julia> **using MyTest*

*ERROR: ArgumentError: MyTest not found in path*

* in require at 
/Applications/Julia-0.4.2.app/Contents/Resources/julia/lib/julia/sys.dylib*


What am I doing wrong here?

Thanks