warnings cleanup
Work on #523 in master
Improvement for #523, wrt EnumMapDeserializer, but only for 2.5 (due to minor refactorings).