Commit 926e04d
Fixed bug where Special Values of Float and Double were not parsed from
String and threw an exception.
The bug consists in the fact that NaN / Infinity / -Infinity are
interpreted as a String (which it is). I added a check that if the
expected Class is Float / Double (or float / double) and getText()
returns NaN / Infinity / -Infinity (case-insensitive), the Parses omits
checking that there is no JsonString Annotation.
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=1010108861 parent bec59ea commit 926e04d
File tree
1 file changed
+11
-2
lines changed- google-http-client/src/main/java/com/google/api/client/json
1 file changed
+11
-2
lines changedLines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| 38 | + | |
38 | 39 | | |
39 | 40 | | |
40 | 41 | | |
| |||
842 | 843 | | |
843 | 844 | | |
844 | 845 | | |
845 | | - | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
| 849 | + | |
| 850 | + | |
| 851 | + | |
| 852 | + | |
| 853 | + | |
| 854 | + | |
846 | 855 | | |
847 | 856 | | |
848 | 857 | | |
849 | | - | |
| 858 | + | |
850 | 859 | | |
851 | 860 | | |
852 | 861 | | |
| |||
0 commit comments