Permalink
Browse files

Fix several miscellaneous compiler/Eclipse warnings

 - Suppress an (intentional) AspectJ warning
 - Remove unused imports
 - Suppress a [hiding] warning
 - Fix a generics warning related to extension of final types

Issue: SPR-9431
  • Loading branch information...
1 parent 15e9fe6 commit 662a02b952126c726fe0db16179a6b4595cc08b9 @cbeams cbeams committed Jan 4, 2013
View
5 spring-aspects/src/test/java/org/springframework/aop/aspectj/autoproxy/CodeStyleAspect.aj
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2012 the original author or authors.
+ * Copyright 2002-2013 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,6 +16,8 @@
package org.springframework.aop.aspectj.autoproxy;
+import org.aspectj.lang.annotation.SuppressAjWarnings;
+
/**
* @author Adrian Colyer
*/
@@ -25,6 +27,7 @@ public aspect CodeStyleAspect {
pointcut somePC() : call(* someMethod());
+ @SuppressAjWarnings("adviceDidNotMatch")
before() : somePC() {
System.out.println("match");
}
View
1 ...test/java/org/springframework/context/annotation/AnnotationProcessorPerformanceTests.java
@@ -17,7 +17,6 @@
package org.springframework.context.annotation;
import static org.junit.Assert.*;
-import static org.junit.Assume.assumeFalse;
import javax.annotation.Resource;
View
18 ...ext/src/test/java/org/springframework/context/annotation/BeanMethodPolymorphismTests.java
@@ -1,3 +1,19 @@
+/*
+ * Copyright 2002-2013 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
package org.springframework.context.annotation;
import static org.hamcrest.CoreMatchers.equalTo;
@@ -31,7 +47,7 @@
@Test
public void beanMethodOverloadingWithoutInheritance() {
- @SuppressWarnings("unused")
+ @SuppressWarnings({ "unused", "hiding" })
@Configuration class Config {
@Bean String aString() { return "na"; }
@Bean String aString(Integer dependency) { return "na"; }
View
1 ...est/java/org/springframework/scheduling/concurrent/ScheduledExecutorFactoryBeanTests.java
@@ -28,7 +28,6 @@
import static org.junit.Assert.*;
import static org.mockito.BDDMockito.*;
-import static org.mockito.Mockito.*;
/**
* @author Rick Evans
View
4 spring-core/src/test/java/org/springframework/core/BridgeMethodResolverTests.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2012 the original author or authors.
+ * Copyright 2002-2013 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -1048,7 +1048,7 @@ public void saveOrUpdate(T t) {
}
- public class GenericSqlMapIntegerDao<T extends Integer> extends GenericSqlMapDao<T> {
+ public class GenericSqlMapIntegerDao<T extends Number> extends GenericSqlMapDao<T> {
@Override
public void saveOrUpdate(T t) {

0 comments on commit 662a02b

Please sign in to comment.