I am still new to Julia (about a year in and I am only starting to get it), so please bear with me.
So I was wondering what I could do with the type Base.KeySet
which has supertype AbstractSet{K} where K
. Currently, methods defined for Base.KeySet
seems to be limited to
in(k, v::Base.KeySet) in Base at abstractdict.jl:63
Ok, fine. However, AbstractSet{K} where K
has other methods defined for, such as:
setdiff!(s::AbstractSet, itr) in Base at abstractset.jl:167
In my head, I figured the methods defined for the supertype would also work for the methods defined for the subtype. However, the method above, does not work for type Base.KeySet
.
I suppose I still have not quite gotten yet how types are meant to work in Julia, but I expected that Base.KeySet
would behave as a AbstractSet{K} where K
where behaviour is defined over methods, is this not correct?
Pedro