Skip to content

Commit

Permalink
Merge pull request #507 from nolta/master2
Browse files Browse the repository at this point in the history
fix #472 (command line arguments are broken)
  • Loading branch information
StefanKarpinski committed Mar 3, 2012
2 parents abfe9f6 + 4834c1a commit 57c8595
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion j/client.j
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ function parse_input_line(s::String)
end

function process_options(args::Array{Any,1})
global ARGS
quiet = false
repl = true
if has(ENV, "JL_POST_BOOT")
Expand All @@ -128,12 +129,16 @@ function process_options(args::Array{Any,1})
# TODO: support long options
repl = false
i+=1
ARGS = args[i+1:end]
eval(parse_input_line(args[i]))
break
elseif args[i]=="-E"
repl = false
i+=1
ARGS = args[i+1:end]
show(eval(parse_input_line(args[i])))
println()
break
elseif args[i]=="-P"
i+=1
eval(parse_input_line(args[i]))
Expand All @@ -157,7 +162,6 @@ function process_options(args::Array{Any,1})
elseif args[i][1]!='-'
# program
repl = false
global ARGS
# remove julia's arguments
ARGS = ARGS[i:end]
include(args[i])
Expand Down

0 comments on commit 57c8595

Please sign in to comment.