File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
test/junit/scala/collection Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ class StringParsersTest {
13
13
def doubleOK (str : String ): Unit = assertTrue(
14
14
s " str.toDouble <> str.toDoubleOption for $str" ,
15
15
(str.toDoubleOption, Try (str.toDouble).toOption) match {
16
- case (Some (d1), Some (d2)) if d1.isNaN && d2.isNaN => true
16
+ case (Some (d1), Some (d2)) => d1.isNaN && d2.isNaN || d1 == d2
17
17
case (o1, o2) => o1 == o2
18
18
})
19
19
@@ -242,11 +242,16 @@ class StringParsersTest {
242
242
" -0x0.000000000000090000000000000000001p-1022" ,
243
243
" -0x0.00000000000009fffffffffffffffffffffffffffffffffp-1022" ,
244
244
" -0x0.0000000000000fffffffffffffffffffffffffffffffffffp-1022" ,
245
+ " " ,
246
+ " ." ,
245
247
" .4" ,
246
248
" .E4" ,
249
+ " .E" ,
250
+ " .x" ,
251
+ " .1E4" ,
252
+ " 4." ,
247
253
" 1.1E4" ,
248
254
" 1.E4" ,
249
- " .1E4" ,
250
255
" 1E4" ,
251
256
" E4" ,
252
257
" 0.0" ,
You can’t perform that action at this time.
0 commit comments