You can't redefine types in Base in the REPL, however you can create a 
module to wrap your work - I generally use "dev", for development. Then 
reloading just redefines "dev" which works fine.

module dev
....
all your code
....
end

On Saturday, 15 February 2014 12:30:01 UTC, Andy M wrote:
>
> I am writing a small program in Julia, and I am wondering if my current 
> workflow can be improved.
>
> Currently I use sublime text and a terminal. I have a file which I want to 
> run each time I make some changes. At the moment, I just go to the terminal 
> and type 'include("MyFile.jl")' each time I want to test the program.
> Is there a better way of doing things?
>
> In practise I usually have to close and reopen my instance of Julia each 
> time I run the file, because otherwise I get errors about types being 
> redefined, and I worry about the old code interfering. This means it's 
> actually more annoying to get quick feedback than it would be in most 
> static languages, where I would just have a keyboard shortcut mapped to 
> "Compile & Run".
>
> I tried using Julia Studio, but I found that resetting its REPL takes a 
> very long time for some reason, and it seems to behave very differently to 
> the normal Julia REPL (I got errors in a different, unreadable format, and 
> errors which did not occur under the normal REPL).
>
> I also tried the IJulia Notebook about a month ago, but I am confined to a 
> windows machine and it didn't seem to be fully functional at the time. 
> Perhaps that has changed?
>

Reply via email to