@@ -308,12 +308,11 @@ public void testJdk170NoDebugInfoFor() throws Exception {
308308 String source = decompile (loader , new PlainTextPrinter (), internalClassName );
309309
310310 // Check decompiled source code
311- assertTrue (source .matches (PatternMaker .make ("for (byte b = 0; b < 10; b++)" )));
312- assertTrue (source .matches (PatternMaker .make ("for (byte b = 0;; b++)" )));
313- assertTrue (source .matches (PatternMaker .make ("for (byte b = 0; b < 10; b++)" )));
311+ assertTrue (source .matches (PatternMaker .make ("for (int i = 0; i < 10; i++)" )));
312+ assertTrue (source .matches (PatternMaker .make ("for (int i = 0;; i++)" )));
314313 assertTrue (source .matches (PatternMaker .make ("for (String str : paramList)" )));
315314 assertTrue (source .matches (PatternMaker .make ("for (paramInt = 0; paramInt < 10; paramInt++)" )));
316- assertTrue (source .matches (PatternMaker .make ("for (int i : new int[] { 4 })" )));
315+ assertTrue (source .matches (PatternMaker .make ("for (int j : new int[] { 4 })" )));
317316 assertTrue (source .matches (PatternMaker .make ("for (String str : paramArrayOfString)" )));
318317 assertTrue (source .matches (PatternMaker .make ("for (String str : paramList)" )));
319318
@@ -330,16 +329,16 @@ public void testJdk150For() throws Exception {
330329 String source = decompile (loader , new PlainTextPrinter (), internalClassName , configuration );
331330
332331 // Check decompiled source code
333- assertTrue (source .matches (PatternMaker .make (": 20 */" , "for (byte b = 0; b < 10; b ++)" )));
332+ assertTrue (source .matches (PatternMaker .make (": 20 */" , "for (int i = 0; i < 10; i ++)" )));
334333 assertTrue (source .matches (PatternMaker .make (": 88 */" , "while (paramInt < 10)" )));
335334 assertTrue (source .matches (PatternMaker .make (": 273 */" , "for (paramInt = 0; paramInt < 10; paramInt++)" )));
336- assertTrue (source .matches (PatternMaker .make (": 310 */" , "for (int i : new int[] { 4 })" )));
335+ assertTrue (source .matches (PatternMaker .make (": 310 */" , "for (int j : new int[] { 4 })" )));
337336 assertTrue (source .matches (PatternMaker .make ("/* 347: 0 */" , "do {" )));
338- assertTrue (source .matches (PatternMaker .make (": 349 */" , "while (b < 10);" )));
337+ assertTrue (source .matches (PatternMaker .make (": 349 */" , "while (i < 10);" )));
339338 assertTrue (source .matches (PatternMaker .make (": 385 */" , "for (String str : paramArrayOfString)" )));
340339 assertTrue (source .matches (PatternMaker .make (": 399 */" , "for (String str : paramList)" )));
341340 assertTrue (source .matches (PatternMaker .make (": 411 */" , "Iterator<Class<?>> iterator = Arrays.<Class<?>>asList(getClass().getInterfaces()).iterator()" )));
342- assertTrue (source .matches (PatternMaker .make (": 427 */" , "for (byte b = 0; b < 3; b ++)" )));
341+ assertTrue (source .matches (PatternMaker .make (": 427 */" , "for (int i = 0; i < 3; i ++)" )));
343342
344343 // Recompile decompiled source code and check errors
345344 assertTrue (CompilerUtil .compile ("1.5" , new JavaSourceFileObject (internalClassName , source )));
0 commit comments