I still think it should be a queue.  It's unlikely to land in v0.10 so ABI compatibility is not an issue and I don't want to have to worry about potential denial-of-services because of the O(n) insertion behavior.

By the way, you can drop the cast.