The original simple version I had was:
function mapdict!(f, d::Dict)
L = length(d.vals)
i = d.idxfloor
vals = d.vals
Base.@inbounds while i < L
Base.isslotfilled(d, i) && (vals[i] = f(vals[i]))
i += 1
end
end
Is only about 10% faster without the functionality.