IDEA-138578 Debugger spuriously jumps to decompiled method signature
This commit is contained in:
@@ -58,4 +58,37 @@ public class TestClassLoop {
|
||||
System.out.println("4");
|
||||
}
|
||||
}
|
||||
|
||||
public static int testWhileCombined(String in) {
|
||||
int len = in.length();
|
||||
int i = 0;
|
||||
boolean decSeen = false;
|
||||
boolean signSeen = false;
|
||||
int decPt = 0;
|
||||
char c;
|
||||
int nLeadZero = 0;
|
||||
int nTrailZero= 0;
|
||||
|
||||
skipLeadingZerosLoop:
|
||||
while (i < len) {
|
||||
c = in.charAt(i);
|
||||
if (c == '0') {
|
||||
nLeadZero++;
|
||||
} else if (c == '.') {
|
||||
if (decSeen) {
|
||||
// already saw one ., this is the 2nd.
|
||||
throw new NumberFormatException("multiple points");
|
||||
}
|
||||
decPt = i;
|
||||
if (signSeen) {
|
||||
decPt -= 1;
|
||||
}
|
||||
decSeen = true;
|
||||
} else {
|
||||
break skipLeadingZerosLoop;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
return decPt;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user