Replace anonymous inner classes with lambda declarations (when possible using method references). See gh-9781