Skip to content

Commit

Permalink
merge in
Browse files Browse the repository at this point in the history
  • Loading branch information
jakebolewski committed Oct 9, 2014
2 parents 091ffc1 + f1b00f8 commit 8dd68da
Show file tree
Hide file tree
Showing 44 changed files with 1,432 additions and 272 deletions.
4 changes: 0 additions & 4 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@
[submodule "deps/Rmath"]
path = deps/Rmath
url = git://github.com/JuliaLang/Rmath.git
[submodule "doc/juliadoc"]
path = doc/juliadoc
url = git://github.com/JuliaLang/JuliaDoc.git

[submodule "deps/libmojibake"]
path = deps/libmojibake
url = git://github.com/JuliaLang/libmojibake.git
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,9 @@ endif
-gtk-update-icon-cache $(DESTDIR)$(datarootdir)/icons/hicolor/
mkdir -p $(DESTDIR)$(datarootdir)/applications/
$(INSTALL_F) contrib/julia.desktop $(DESTDIR)$(datarootdir)/applications/
# Install appdata file
mkdir -p $(DESTDIR)$(datarootdir)/appdata/
$(INSTALL_F) contrib/julia.appdata.xml $(DESTDIR)$(datarootdir)/appdata/

# Update RPATH entries and JL_SYSTEM_IMAGE_PATH if $(private_libdir_rel) != $(build_private_libdir_rel)
ifneq ($(private_libdir_rel),$(build_private_libdir_rel))
Expand Down
19 changes: 13 additions & 6 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ Library improvements

* `deepcopy` recurses through immutable types and makes copies of their mutable fields ([#8560]).

Deprecated or removed
---------------------

* `median` and `median!` no longer accept a `checknan` keyword argument ([#8605]).

Julia v0.3.0 Release Notes
==========================

Expand Down Expand Up @@ -852,6 +857,7 @@ Too numerous to mention.
[#3688]: https://github.com/JuliaLang/julia/issues/3688
[#3697]: https://github.com/JuliaLang/julia/issues/3697
[#3719]: https://github.com/JuliaLang/julia/issues/3719
[#3759]: https://github.com/JuliaLang/julia/issues/3759
[#3790]: https://github.com/JuliaLang/julia/issues/3790
[#3819]: https://github.com/JuliaLang/julia/issues/3819
[#3872]: https://github.com/JuliaLang/julia/issues/3872
Expand Down Expand Up @@ -913,6 +919,7 @@ Too numerous to mention.
[#5381]: https://github.com/JuliaLang/julia/issues/5381
[#5387]: https://github.com/JuliaLang/julia/issues/5387
[#5403]: https://github.com/JuliaLang/julia/issues/5403
[#5413]: https://github.com/JuliaLang/julia/issues/5413
[#5423]: https://github.com/JuliaLang/julia/issues/5423
[#5427]: https://github.com/JuliaLang/julia/issues/5427
[#5428]: https://github.com/JuliaLang/julia/issues/5428
Expand Down Expand Up @@ -962,6 +969,7 @@ Too numerous to mention.
[#6678]: https://github.com/JuliaLang/julia/issues/6678
[#6716]: https://github.com/JuliaLang/julia/issues/6716
[#6726]: https://github.com/JuliaLang/julia/issues/6726
[#6739]: https://github.com/JuliaLang/julia/issues/6739
[#6769]: https://github.com/JuliaLang/julia/issues/6769
[#6773]: https://github.com/JuliaLang/julia/issues/6773
[#6911]: https://github.com/JuliaLang/julia/issues/6911
Expand All @@ -981,6 +989,7 @@ Too numerous to mention.
[#7146]: https://github.com/JuliaLang/julia/issues/7146
[#7236]: https://github.com/JuliaLang/julia/issues/7236
[#7242]: https://github.com/JuliaLang/julia/issues/7242
[#7311]: https://github.com/JuliaLang/julia/issues/7311
[#7359]: https://github.com/JuliaLang/julia/issues/7359
[#7365]: https://github.com/JuliaLang/julia/issues/7365
[#7373]: https://github.com/JuliaLang/julia/issues/7373
Expand All @@ -990,14 +999,12 @@ Too numerous to mention.
[#7513]: https://github.com/JuliaLang/julia/issues/7513
[#7647]: https://github.com/JuliaLang/julia/issues/7647
[#7654]: https://github.com/JuliaLang/julia/issues/7654
[#7704]: https://github.com/JuliaLang/julia/issues/7704
[#7917]: https://github.com/JuliaLang/julia/issues/7917
[#7992]: https://github.com/JuliaLang/julia/issues/7992
[#8011]: https://github.com/JuliaLang/julia/issues/8011
[#8089]: https://github.com/JuliaLang/julia/issues/8089
[#7704]: https://github.com/JuliaLang/julia/issues/7704
[#5413]: https://github.com/JuliaLang/julia/issues/5413
[#3759]: https://github.com/JuliaLang/julia/issues/3759
[#7311]: https://github.com/JuliaLang/julia/issues/7311
[#8152]: https://github.com/JuliaLang/julia/issues/8152
[#8423]: https://github.com/JuliaLang/julia/issues/8423
[#8152]: https://github.com/JuliaLang/julia/pull/8152
[#6739]: https://github.com/JuliaLang/julia/issues/6739
[#8560]: https://github.com/JuliaLang/julia/issues/8560
[#8605]: https://github.com/JuliaLang/julia/issues/8605
2 changes: 1 addition & 1 deletion base/array.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1148,7 +1148,7 @@ indmin(a) = findmin(a)[2]
# similar to Matlab's ismember
# returns a vector containing the highest index in b for each value in a that is a member of b
function indexin(a::AbstractArray, b::AbstractArray)
bdict = Dict(b, 1:length(b))
bdict = Dict(zip(b, 1:length(b)))
[get(bdict, i, 0) for i in a]
end

Expand Down
10 changes: 10 additions & 0 deletions base/deprecated.jl
Original file line number Diff line number Diff line change
Expand Up @@ -185,3 +185,13 @@ const Nothing = Void

export None
const None = Union()

@deprecate median(v::AbstractArray; checknan::Bool=true) median(v)
@deprecate median(v::AbstractArray, region; checknan::Bool=true) median(v, region)
@deprecate median!(v::AbstractVector; checknan::Bool=true) median!(v)

@deprecate Dict{K,V}(ks::AbstractArray{K}, vs::AbstractArray{V}) Dict{K,V}(zip(ks, vs))
@deprecate Dict{K,V}(ks::(K...), vs::(V...)) Dict{K,V}(zip(ks, vs))
@deprecate Dict{K}(ks::(K...), vs::Tuple) Dict{K,Any}(zip(ks, vs))
@deprecate Dict{V}(ks::Tuple, vs::(V...)) Dict{Any,V}(zip(ks, vs))
@deprecate Dict(ks, vs) Dict{Any,Any}(zip(ks, vs))
24 changes: 15 additions & 9 deletions base/dict.jl
Original file line number Diff line number Diff line change
Expand Up @@ -341,18 +341,22 @@ Dict(kv::()) = Dict()
const AnyDict = Dict{Any,Any}

# TODO: this can probably be simplified using `eltype` as a THT (Tim Holy trait)
Dict{K,V}(kv::((K,V)...,)) = Dict{K,V}(kv)
Dict{K }(kv::((K,Any)...,)) = Dict{K,Any}(kv)
Dict{V }(kv::((Any,V)...,)) = Dict{Any,V}(kv)
Dict{K,V}(kv::(Pair{K,V}...,)) = Dict{K,V}(kv)
Dict (kv::(Pair...,)) = Dict{Any,Any}(kv)
Dict{K,V}(kv::((K,V)...,)) = Dict{K,V}(kv)
Dict{K }(kv::((K,Any)...,)) = Dict{K,Any}(kv)
Dict{V }(kv::((Any,V)...,)) = Dict{Any,V}(kv)
Dict{K,V}(kv::(Pair{K,V}...,)) = Dict{K,V}(kv)
Dict{K} (kv::(Pair{K}...,)) = Dict{K,Any}(kv)
Dict{V} (kv::(Pair{TypeVar(:K),V}...,)) = Dict{Any,V}(kv)
Dict (kv::(Pair...,)) = Dict{Any,Any}(kv)

Dict{K,V}(kv::AbstractArray{(K,V)}) = Dict{K,V}(kv)
Dict{K,V}(kv::AbstractArray{Pair{K,V}}) = Dict{K,V}(kv)
Dict{K,V}(kv::Associative{K,V}) = Dict{K,V}(kv)

Dict{K,V}(ps::Pair{K,V}...) = Dict{K,V}(ps)
Dict (ps::Pair...) = Dict{Any,Any}(ps)
Dict{K,V}(ps::Pair{K,V}...) = Dict{K,V}(ps)
Dict{K} (ps::Pair{K}...,) = Dict{K,Any}(ps)
Dict{V} (ps::Pair{TypeVar(:K),V}...,) = Dict{Any,V}(ps)
Dict (ps::Pair...) = Dict{Any,Any}(ps)

Dict(kv) = dict_with_eltype(kv, eltype(kv))
dict_with_eltype{K,V}(kv, ::Type{(K,V)}) = Dict{K,V}(kv)
Expand Down Expand Up @@ -468,8 +472,10 @@ end
function empty!{K,V}(h::Dict{K,V})
fill!(h.slots, 0x0)
sz = length(h.slots)
h.keys = Array(K, sz)
h.vals = Array(V, sz)
empty!(h.keys)
empty!(h.vals)
resize!(h.keys, sz)
resize!(h.vals, sz)
h.ndel = 0
h.count = 0
return h
Expand Down
20 changes: 20 additions & 0 deletions base/intfuncs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,26 @@ function gcd{T<:Integer}(a::T, b::T)
abs(a)
end

# binary GCD (aka Stein's) algorithm
# about 1.7x (2.1x) faster for random Int64s (Int128s)
function gcd{T<:Union(Int64,Uint64,Int128,Uint128)}(a::T, b::T)
a == 0 && return abs(b)
b == 0 && return abs(a)
za = trailing_zeros(a)
zb = trailing_zeros(b)
k = min(za, zb)
u = abs(a >> za)
v = abs(b >> zb)
while u != v
if u > v
u, v = v, u
end
v -= u
v >>= trailing_zeros(v)
end
u << k
end

# explicit a==0 test is to handle case of lcm(0,0) correctly
lcm{T<:Integer}(a::T, b::T) = a == 0 ? a : abs(a * div(b, gcd(b,a)))

Expand Down
8 changes: 4 additions & 4 deletions base/linalg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -162,21 +162,21 @@ end
#Check that stride of matrix/vector is 1
function chkstride1(A::StridedVecOrMat...)
for a in A
stride(a,1)== 1 || error("Matrix does not have contiguous columns")
stride(a,1)== 1 || error("matrix does not have contiguous columns")
end
end

#Check that matrix is square
function chksquare(A::AbstractMatrix)
m,n = size(A)
m == n || throw(DimensionMismatch("Matrix is not square"))
m == n || throw(DimensionMismatch("matrix is not square"))
m
end

function chksquare(A...)
sizes=Int[]
sizes = Int[]
for a in A
size(a,1)==size(a,2) || throw(DimensionMismatch("Matrix is not square: dimensions are $(size(a))"))
size(a,1)==size(a,2) || throw(DimensionMismatch("matrix is not square: dimensions are $(size(a))"))
push!(sizes, size(a,1))
end
length(A)==1 ? sizes[1] : sizes
Expand Down
18 changes: 9 additions & 9 deletions base/linalg/factorization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ end
# Note. For QRCompactWY factorization without pivoting, the WY representation based method introduced in LAPACK 3.4
immutable QRCompactWY{S} <: Factorization{S}
factors::Matrix{S}
T::Triangular{S}
T::Matrix{S}
end
QRCompactWY{S}(factors::Matrix{S}, T::Matrix{S})=QRCompactWY{S}(factors, Triangular(T, :U))
QRCompactWY{S}(factors::Matrix{S}, T::Matrix{S})=QRCompactWY{S}(factors, T)

immutable QRPivoted{T} <: Factorization{T}
factors::Matrix{T}
Expand Down Expand Up @@ -113,7 +113,7 @@ immutable QRPackedQ{T} <: AbstractMatrix{T}
end
immutable QRCompactWYQ{S} <: AbstractMatrix{S}
factors::Matrix{S}
T::Triangular{S}
T::Matrix{S}
end

convert{T}(::Type{QRPackedQ{T}}, Q::QRPackedQ) = QRPackedQ(convert(AbstractMatrix{T}, Q.factors), convert(Vector{T}, Q.τ))
Expand All @@ -130,7 +130,7 @@ full{T}(A::Union(QRPackedQ{T},QRCompactWYQ{T}); thin::Bool=true) = A_mul_B!(A, t

## Multiplication by Q
### QB
A_mul_B!{T<:BlasFloat}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','N',A.factors,A.T.data,B)
A_mul_B!{T<:BlasFloat}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','N',A.factors,A.T,B)
A_mul_B!{T<:BlasFloat}(A::QRPackedQ{T}, B::StridedVecOrMat{T}) = LAPACK.ormqr!('L','N',A.factors,A.τ,B)
function A_mul_B!{T}(A::QRPackedQ{T}, B::AbstractVecOrMat{T})
mA, nA = size(A.factors)
Expand Down Expand Up @@ -167,8 +167,8 @@ function *{TA,TB}(A::Union(QRPackedQ{TA},QRCompactWYQ{TA}), B::StridedMatrix{TB}
A_mul_B!(Anew,Bnew)
end
### QcB
Ac_mul_B!{T<:BlasReal}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','T',A.factors,A.T.data,B)
Ac_mul_B!{T<:BlasComplex}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','C',A.factors,A.T.data,B)
Ac_mul_B!{T<:BlasReal}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','T',A.factors,A.T,B)
Ac_mul_B!{T<:BlasComplex}(A::QRCompactWYQ{T}, B::StridedVecOrMat{T}) = LAPACK.gemqrt!('L','C',A.factors,A.T,B)
Ac_mul_B!{T<:BlasReal}(A::QRPackedQ{T}, B::StridedVecOrMat{T}) = LAPACK.ormqr!('L','T',A.factors,A.τ,B)
Ac_mul_B!{T<:BlasComplex}(A::QRPackedQ{T}, B::StridedVecOrMat{T}) = LAPACK.ormqr!('L','C',A.factors,A.τ,B)
function Ac_mul_B!{T}(A::QRPackedQ{T}, B::AbstractVecOrMat{T})
Expand Down Expand Up @@ -198,7 +198,7 @@ function Ac_mul_B{TQ<:Number,TB<:Number,N}(Q::Union(QRPackedQ{TQ},QRCompactWYQ{T
Ac_mul_B!(convert(AbstractMatrix{TQB}, Q), TB == TQB ? copy(B) : convert(AbstractArray{TQB,N}, B))
end
### AQ
A_mul_B!{T<:BlasFloat}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','N', B.factors, B.T.data, A)
A_mul_B!{T<:BlasFloat}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','N', B.factors, B.T, A)
A_mul_B!(A::StridedVecOrMat, B::QRPackedQ) = LAPACK.ormqr!('R', 'N', B.factors, B.τ, A)
function A_mul_B!{T}(A::StridedMatrix{T},Q::QRPackedQ{T})
mQ, nQ = size(Q.factors)
Expand Down Expand Up @@ -227,8 +227,8 @@ function *{TA,TQ,N}(A::StridedArray{TA,N}, Q::Union(QRPackedQ{TQ},QRCompactWYQ{T
A_mul_B!(TA==TAQ ? copy(A) : convert(AbstractArray{TAQ,N}, A), convert(AbstractMatrix{TAQ}, Q))
end
### AQc
A_mul_Bc!{T<:BlasReal}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','T',B.factors,B.T.data,A)
A_mul_Bc!{T<:BlasComplex}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','C',B.factors,B.T.data,A)
A_mul_Bc!{T<:BlasReal}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','T',B.factors,B.T,A)
A_mul_Bc!{T<:BlasComplex}(A::StridedVecOrMat{T}, B::QRCompactWYQ{T}) = LAPACK.gemqrt!('R','C',B.factors,B.T,A)
A_mul_Bc!{T<:BlasReal}(A::StridedVecOrMat{T}, B::QRPackedQ{T}) = LAPACK.ormqr!('R','T',B.factors,B.τ,A)
A_mul_Bc!{T<:BlasComplex}(A::StridedVecOrMat{T}, B::QRPackedQ{T}) = LAPACK.ormqr!('R','C',B.factors,B.τ,A)
function A_mul_Bc!{T}(A::AbstractMatrix{T},Q::QRPackedQ{T})
Expand Down
20 changes: 10 additions & 10 deletions base/linalg/matmul.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ arithtype(T) = T
arithtype(::Type{Bool}) = Int

# multiply by diagonal matrix as vector
function scale!(C::Matrix, A::Matrix, b::Vector)
function scale!(C::AbstractMatrix, A::AbstractMatrix, b::AbstractVector)
m, n = size(A)
n==length(b) || throw(DimensionMismatch(""))
n == length(b) || throw(DimensionMismatch(""))
for j = 1:n
bj = b[j]
for i = 1:m
Expand All @@ -16,10 +16,10 @@ function scale!(C::Matrix, A::Matrix, b::Vector)
C
end

function scale!(C::Matrix, b::Vector, A::Matrix)
function scale!(C::AbstractMatrix, b::AbstractVector, A::AbstractMatrix)
m, n = size(A)
m==length(b) || throw(DimensionMismatch(""))
for j=1:n, i=1:m
m == length(b) || throw(DimensionMismatch(""))
for j = 1:n, i = 1:m
C[i,j] = A[i,j]*b[i]
end
C
Expand All @@ -29,8 +29,8 @@ scale(b::Vector, A::Matrix) = scale!(similar(b, promote_type(eltype(A),eltype(b)

# Dot products

dot{T<:BlasReal}(x::Vector{T}, y::Vector{T}) = BLAS.dot(x, y)
dot{T<:BlasComplex}(x::Vector{T}, y::Vector{T}) = BLAS.dotc(x, y)
dot{T<:BlasReal}(x::StridedVector{T}, y::StridedVector{T}) = BLAS.dot(x, y)
dot{T<:BlasComplex}(x::StridedVector{T}, y::StridedVector{T}) = BLAS.dotc(x, y)
function dot{T<:BlasReal, TI<:Integer}(x::Vector{T}, rx::Union(UnitRange{TI},Range{TI}), y::Vector{T}, ry::Union(UnitRange{TI},Range{TI}))
length(rx)==length(ry) || throw(DimensionMismatch(""))
if minimum(rx) < 1 || maximum(rx) > length(x) || minimum(ry) < 1 || maximum(ry) > length(y)
Expand Down Expand Up @@ -58,9 +58,9 @@ function dot(x::AbstractVector, y::AbstractVector)
s
end
dot(x::Number, y::Number) = conj(x) * y
Ac_mul_B(x::Vector, y::Vector) = [dot(x, y)]
At_mul_B{T<:Real}(x::Vector{T}, y::Vector{T}) = [dot(x, y)]
At_mul_B{T<:BlasComplex}(x::Vector{T}, y::Vector{T}) = [BLAS.dotu(x, y)]
Ac_mul_B(x::AbstractVector, y::AbstractVector) = [dot(x, y)]
At_mul_B{T<:Real}(x::AbstractVector{T}, y::AbstractVector{T}) = [dot(x, y)]
At_mul_B{T<:BlasComplex}(x::StridedVector{T}, y::StridedVector{T}) = [BLAS.dotu(x, y)]

# Matrix-vector multiplication
function (*){T<:BlasFloat,S}(A::StridedMatrix{T}, x::StridedVector{S})
Expand Down
3 changes: 2 additions & 1 deletion base/linalg/triangular.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ immutable Triangular{T,S<:AbstractMatrix{T},UpLo,IsUnit} <: AbstractMatrix{T}
data::S
end
function Triangular{T}(A::AbstractMatrix{T}, uplo::Symbol, isunit::Bool=false)
chksquare(A)
uplo != :L && uplo != :U && throw(ArgumentError("uplo argument must be either :U or :L"))
return Triangular{T,typeof(A),uplo,isunit}(A)
end
Expand Down Expand Up @@ -144,7 +145,7 @@ fill!(A::Triangular, x) = (fill!(A.data, x); A)

function similar{T,S,UpLo,IsUnit,Tnew}(A::Triangular{T,S,UpLo,IsUnit}, ::Type{Tnew}, dims::Dims)
dims[1] == dims[2] || throw(ArgumentError("a Triangular matrix must be square"))
length(dims) == 2 || throw(ArgumentError("a Traigular matrix must have two dimensions"))
length(dims) == 2 || throw(ArgumentError("a Triangular matrix must have two dimensions"))
A = similar(A.data, Tnew, dims)
return Triangular{Tnew, typeof(A), UpLo, IsUnit}(A)
end
Expand Down
28 changes: 17 additions & 11 deletions base/multi.jl
Original file line number Diff line number Diff line change
Expand Up @@ -797,7 +797,7 @@ function accept_handler(server::TCPServer, status::Int32)
end

function create_message_handler_loop(sock::AsyncStream; ntfy_join_complete=nothing) #returns immediately
schedule(@task begin
@schedule begin
global PGRP
#println("message_handler_loop")
disable_nagle(sock)
Expand All @@ -823,26 +823,32 @@ function create_message_handler_loop(sock::AsyncStream; ntfy_join_complete=nothi
id = deserialize(sock)
f = deserialize(sock)
args = deserialize(sock)
@schedule begin
v = run_work_thunk(()->f(args...))
deliver_result(sock, msg, id, v)
v
let f=f, args=args, id=id, msg=msg
@schedule begin
v = run_work_thunk(()->f(args...))
deliver_result(sock, msg, id, v)
v
end
end
elseif is(msg, :call_wait)
id = deserialize(sock)
notify_id = deserialize(sock)
f = deserialize(sock)
args = deserialize(sock)
@schedule begin
rv = schedule_call(id, ()->f(args...))
deliver_result(sock, msg, notify_id, wait_full(rv))
let f=f, args=args, id=id, msg=msg, notify_id=notify_id
@schedule begin
rv = schedule_call(id, ()->f(args...))
deliver_result(sock, msg, notify_id, wait_full(rv))
end
end
elseif is(msg, :do)
f = deserialize(sock)
args = deserialize(sock)
#print("got args: $args\n")
@schedule begin
run_work_thunk(RemoteValue(), ()->f(args...))
let f=f, args=args
@schedule begin
run_work_thunk(RemoteValue(), ()->f(args...))
end
end
elseif is(msg, :result)
# used to deliver result of wait or fetch
Expand Down Expand Up @@ -924,7 +930,7 @@ function create_message_handler_loop(sock::AsyncStream; ntfy_join_complete=nothi

return nothing
end
end)
end
end

function disable_threaded_libs()
Expand Down
2 changes: 1 addition & 1 deletion base/profile.jl
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ end

function getdict(data::Vector{Uint})
uip = unique(data)
Dict(uip, [lookup(ip) for ip in uip])
Dict{Uint, LineInfo}([ip=>lookup(ip) for ip in uip])
end

function callers(funcname::ByteString, bt::Vector{Uint}, lidict; filename = nothing, linerange = nothing)
Expand Down
Loading

0 comments on commit 8dd68da

Please sign in to comment.