WebMvcConfigurationSupport.beanNameHandlerMapping creates a BeanNameUrlHandlerMapping instance but does not call setPatternParser.

Other mappings in the class have the following code:

PathPatternParser patternParser = getPathMatchConfigurer().getPatternParser();
if (patternParser != null) {
    mapping.setPatternParser(patternParser);
}

Comment From: rstoyanchev

The idea probably was that you don't need it for mappings based on bean names but it looks like patterns are supported.