Set/map bugs, and some more utility functions