Treat all names consistently in map()before()after

All declared names should be treated the same as those in variable
declarations and so be static during maps.