MCPcopy Create free account
hub / github.com/antlr/codebuff / fpPattern

Method fpPattern

output/java_guava/1.4.19/Doubles.java:605–613  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

603 static final Pattern FLOATING_POINT_PATTERN = fpPattern();
604
605 @GwtIncompatible // regular expressions
606 private static Pattern fpPattern() {
607 String decimal = "(?:\\d++(?:\\.\\d*+)?|\\.\\d++)";
608 String completeDec = decimal + "(?:[eE][+-]?\\d++)?[fFdD]?";
609 String hex = "(?:\\p{XDigit}++(?:\\.\\p{XDigit}*+)?|\\.\\p{XDigit}++)";
610 String completeHex = "0[xX]" + hex + "[pP][+-]?\\d++[fFdD]?";
611 String fpPattern = "[+-]?(?:NaN|Infinity|" + completeDec + "|" + completeHex + ")";
612 return Pattern.compile(fpPattern);
613 }
614
615 /**
616 * Parses the specified string as a double-precision floating point value. The ASCII character

Callers 1

DoublesClass · 0.95

Calls 1

compileMethod · 0.45

Tested by

no test coverage detected