Small optimization of reduce visitor