idmap2: move static functions to anonymous namespaces

Move static functions to anonymous namespaces: this is the contemporary
way to express the same thing.

Test: make idmap2_tests
Change-Id: I41ed387455996db1ac515d04eb560d179b5b5169
3 files changed