Skip to content

Commit b290720

Browse files
authored
Change Array to Vector (#142)
1 parent 8d8c0ed commit b290720

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/ordered_dict.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ const global maxprobeshift = isdefined(Base, :maxprobeshift) ? Base.maxprobesh
1111
refers to insertion order, which allows deterministic iteration over the dictionary.
1212
"""
1313
mutable struct OrderedDict{K,V} <: AbstractDict{K,V}
14-
slots::Array{Int32,1}
15-
keys::Array{K,1}
16-
vals::Array{V,1}
14+
slots::Vector{Int32}
15+
keys::Vector{K}
16+
vals::Vector{V}
1717
ndel::Int
1818
maxprobe::Int
1919
dirty::Bool

test/test_little_dict.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ using OrderedCollections: FrozenLittleDict, UnfrozenLittleDict
6969
LittleDict{Int,Float64, Vector{Int}, Vector{Float64}}
7070

7171
@test @inferred(LittleDict{Int, Char}(rand(1:100,20), rand('a':'z', 20))) isa
72-
LittleDict{Int,Char,Array{Int,1},Array{Char,1}}
72+
LittleDict{Int,Char,Vector{Int},Vector{Char}}
7373

7474
# Different number of keys and values
7575
@test_throws ArgumentError LittleDict{Int, Char, Vector{Int}, Vector{Char}}([1,2,3], ['a','b'])

test/test_ordered_set.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ using OrderedCollections, Test
1111
data_in = (1, "banana", ())
1212
s = OrderedSet(data_in)
1313
data_out = collect(s)
14-
@test isa(data_out, Array{Any,1})
14+
@test isa(data_out, Vector{Any})
1515
@test tuple(data_out...) === data_in
1616
@test tuple(data_in...) === tuple(s...)
1717
@test length(data_out) == length(data_in)

0 commit comments

Comments
 (0)