[Fb-contrib-commit] SF.net SVN: fb-contrib: [496] trunk/fb-contrib/src/com/mebigfatguy/fbcontrib/det
Brought to you by:
dbrosius
From: <dbr...@us...> - 2006-04-22 13:18:13
|
Revision: 496 Author: dbrosius Date: 2006-04-22 06:18:00 -0700 (Sat, 22 Apr 2006) ViewCVS: http://svn.sourceforge.net/fb-contrib/?rev=496&view=rev Log Message: ----------- fix false positive due to incomplete changeover to iterative Modified Paths: -------------- trunk/fb-contrib/src/com/mebigfatguy/fbcontrib/detect/FieldCouldBeLocal.java Modified: trunk/fb-contrib/src/com/mebigfatguy/fbcontrib/detect/FieldCouldBeLocal.java =================================================================== --- trunk/fb-contrib/src/com/mebigfatguy/fbcontrib/detect/FieldCouldBeLocal.java 2006-04-19 01:07:38 UTC (rev 495) +++ trunk/fb-contrib/src/com/mebigfatguy/fbcontrib/detect/FieldCouldBeLocal.java 2006-04-22 13:18:00 UTC (rev 496) @@ -204,7 +204,7 @@ visitedBlocks.set(bb.getId()); InstructionIterator ii = bb.instructionIterator(); - while (ii.hasNext()) { + while ((uncheckedFields.size() > 0) && ii.hasNext()) { InstructionHandle ih = ii.next(); Instruction ins = ih.getInstruction(); if (ins instanceof FieldInstruction) { @@ -221,8 +221,6 @@ if (finfo != null) finfo.setSrcLineAnnotation(SourceLineAnnotation.fromVisitedInstruction(clsContext, this, ih.getPosition())); } - if (uncheckedFields.size() == 0) - return; } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |