mirror of
https://github.com/zxing/zxing.git
synced 2024-11-10 04:54:04 -08:00
Changes to the matrix and debug classes to make some tests pass.
I'm not super happy about making LOG_INFO a noop, but I don't know the general solution off hand. In any case, MatrixUtilTestCase and MaskUtilTestCase both pass now. git-svn-id: https://zxing.googlecode.com/svn/trunk@729 59b500cc-1b3d-0410-9834-0bbf25fbcc57
This commit is contained in:
parent
581464ad21
commit
a16d3ba6ef
|
@ -31,7 +31,11 @@ public class Debug {
|
|||
}
|
||||
|
||||
public static void LOG_INFO(String message) {
|
||||
throw new RuntimeException(message);
|
||||
// Chris M -- throwing RuntimeException in an INFO function seems terribly
|
||||
// strange and violates my assumptions about logging information. Even
|
||||
// ERROR is borderline since it's effectively going to go unchecked by most
|
||||
// callers. There has to be a more general way to do this.
|
||||
// throw new RuntimeException(message);
|
||||
}
|
||||
|
||||
public static void DCHECK(boolean condition) {
|
||||
|
|
|
@ -291,7 +291,7 @@ public final class MatrixUtil {
|
|||
public static int FindMSBSet(int value) {
|
||||
int num_digits = 0;
|
||||
while (value != 0) {
|
||||
value >>= 1;
|
||||
value >>>= 1;
|
||||
++num_digits;
|
||||
}
|
||||
return num_digits;
|
||||
|
|
Loading…
Reference in a new issue