Browse Source

Allow AutowiredAnnotationBeanPostProcessor to compile on JDK 11

pull/28119/head
Sam Brannen 3 years ago
parent
commit
669b05dc1d
  1. 6
      spring-beans/src/main/java/org/springframework/beans/factory/annotation/AutowiredAnnotationBeanPostProcessor.java

6
spring-beans/src/main/java/org/springframework/beans/factory/annotation/AutowiredAnnotationBeanPostProcessor.java

@ -537,10 +537,10 @@ public class AutowiredAnnotationBeanPostProcessor implements SmartInstantiationA
* @param ann the Autowired annotation * @param ann the Autowired annotation
* @return whether the annotation indicates that a dependency is required * @return whether the annotation indicates that a dependency is required
*/ */
@SuppressWarnings({"deprecation", "cast"}) @SuppressWarnings("deprecation")
protected boolean determineRequiredStatus(MergedAnnotation<?> ann) { protected boolean determineRequiredStatus(MergedAnnotation<?> ann) {
return determineRequiredStatus( return determineRequiredStatus(ann.<AnnotationAttributes> asMap(
ann.asMap(mergedAnnotation -> new AnnotationAttributes(mergedAnnotation.getType()))); mergedAnnotation -> new AnnotationAttributes(mergedAnnotation.getType())));
} }
/** /**

Loading…
Cancel
Save