keep types in polymap ordered
decouple PolyMap from PathMap, create PolyMap module