aboutsummaryrefslogtreecommitdiffstats
path: root/runtime/src/test/java/org
diff options
context:
space:
mode:
authorLars Grefer <eclipse@larsgrefer.de>2020-08-08 03:06:37 +0200
committerLars Grefer <eclipse@larsgrefer.de>2020-08-08 03:06:37 +0200
commit72194b7982ddfa8e9864d0a9934905bb76b90f33 (patch)
treeebed806c358c1a3960c5d6be4c13b26ca41809df /runtime/src/test/java/org
parentc3289ab86bfb2c97cf34147239b3dde46de92a7c (diff)
downloadaspectj-72194b7982ddfa8e9864d0a9934905bb76b90f33.tar.gz
aspectj-72194b7982ddfa8e9864d0a9934905bb76b90f33.zip
'for' loop replaceable with enhanced 'for' loop
Reports for loops which iterate over collections or arrays, and can be replaced with an enhanced for loop (i.e. the foreach iteration syntax). Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
Diffstat (limited to 'runtime/src/test/java/org')
-rw-r--r--runtime/src/test/java/org/aspectj/internal/lang/reflect/AjTypeWithAspectsTest.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/runtime/src/test/java/org/aspectj/internal/lang/reflect/AjTypeWithAspectsTest.java b/runtime/src/test/java/org/aspectj/internal/lang/reflect/AjTypeWithAspectsTest.java
index af72d26f5..a2f33f91b 100644
--- a/runtime/src/test/java/org/aspectj/internal/lang/reflect/AjTypeWithAspectsTest.java
+++ b/runtime/src/test/java/org/aspectj/internal/lang/reflect/AjTypeWithAspectsTest.java
@@ -146,9 +146,9 @@ public class AjTypeWithAspectsTest extends TestCase {
assertEquals(10,ms.length);
//AV was corrupted, cannot rely on ordering
String match = "";
- for (int i = 0; i < ms.length; i++) {
- match = match + "--" + ms[i].getName();
- }
+ for (Method m : ms) {
+ match = match + "--" + m.getName();
+ }
assertTrue(match.indexOf("aMethod") >=0);
}