There's an issue with the convenience function dictionary when the indices are distinct subtypes of an abstract type, i.e.,
abstract type A end
struct B <: A end
struct C <: A end
b = B()
c = C()
d = dictionary([b => 1, c => 2])
# 2-element Dictionary{A, Int64}
# B() │ 94489280530
# C() │ 2
d = dictionary([b => 1, c => 2])
# 2-element Dictionary{A, Int64}
# B() │ 94489280530
# C() │ 2
d = dictionary([b => 1, c => 2])
# 2-element Dictionary{A, Int64}
# B() │ 0
# C() │ 2
other methods of constructing the Dictionary seem fine, i.e.,
There's an issue with the convenience function
dictionary
when the indices are distinct subtypes of an abstract type, i.e.,other methods of constructing the
Dictionary
seem fine, i.e.,