[hyddd的FindBugs分析记录][M D RCN]Repeated conditional tests
2009-02-13 22:57 hyddd 阅读(2620) 评论(0) 编辑 收藏 举报[M C RpC] Repeated conditional tests [RpC_REPEATED_CONDITIONAL_TEST]
The code contains a conditional test is performed twice, one right after the
other (e.g., x == 0 || x == 0
). Perhaps the second occurrence is
intended to be something else (e.g., x == 0 || y == 0
).
这个不解释,一看代码就知道:
public void test{
String str = "123";
if(str!=null){
if(str!=null){ //重复了
System.out.println("123");
}
}
}
String str = "123";
if(str!=null){
if(str!=null){ //重复了
System.out.println("123");
}
}
}
作者:hyddd
出处:http://www.cnblogs.com/hyddd/
本文版权归作者所有,欢迎转载,演绎或用于商业目的,但是必须说明本文出处(包含链接)。