Skip to content

Commit

Permalink
Merge pull request #11 from lostanlen/patch-2
Browse files Browse the repository at this point in the history
ntuple(n, identity) becomes tuple(collect(1:n)...)
  • Loading branch information
timholy committed Jul 15, 2015
2 parents a05c7cc + ac573d8 commit 45ca2dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Options.jl
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ function Options{T<:OptionsChecking}(::Type{T},args...)
end
n = div(length(args),2)
keys, index, vals = if n > 0
(args[1:2:end], ntuple(n, identity), Any[args[2:2:end]...])
(args[1:2:end], tuple(collect(1:n)...), Any[args[2:2:end]...])
else
((), (), Array(Any, 0))
end
Expand Down

0 comments on commit 45ca2dc

Please sign in to comment.