Strangely though, if I modify the put! function as:

function put!(D::DictChannel, k, v)
    D.d[k] = v
    notify(D.cond_take)
    Println(keys(D.d))
    D
end

And run this I get 

Any[2,3,1]

(I added keps in that order), i.e. This works

So it seemed the function definition of keys does not work in the same way as 
for put! For some reason and I can't figure out why

Reply via email to