#5688: instance Read Integer/Rational/Double readsPrec out of memory and crash 
due
to exponential notation
-------------------------------+--------------------------------------------
  Reporter:  gracjan           |          Owner:  igloo           
      Type:  bug               |         Status:  merge           
  Priority:  highest           |      Milestone:  7.4.2           
 Component:  libraries/base    |        Version:  6.12.3          
Resolution:                    |       Keywords:                  
        Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
   Failure:  Runtime crash     |     Difficulty:  Unknown         
  Testcase:                    |      Blockedby:                  
  Blocking:                    |        Related:                  
-------------------------------+--------------------------------------------
Changes (by igloo):

  * status:  new => merge


Comment:

 Now fixed. This should be the complete patch list:
 {{{
 commit afcddc5ce033de84ab88e73657a2f753aaee785a
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 01:26:06 2012 +0000

     Refactor number lexing; part of #5688

     This doesn't change the behaviour yet, but I think it's a step in the
     right direction.

 commit 480b755a8397e75b6d58992664ab42c8ff0e1907
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 13:42:25 2012 +0000

     Rename lexNum test to lex001, and expand it

 commit 54ce8383cc610977b50f571782f35d1322283a79
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 13:57:54 2012 +0000

     Add a test for reading Doubles

 commit 35ff29d8fdf916c79a01103f0bb40ee6d3b50453
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 13:58:18 2012 +0000

     Change how NaN and Infinity are read by lex

 commit f3c88bed6c742982992ac4edc8b294c3445a157d
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 14:03:31 2012 +0000

     Add a readInteger001 test

 commit bed3d7937bea1619f7cf05af8babd8dd4385f348
 Author: Ian Lynagh <[email protected]>
 Date:   Thu Mar 1 14:05:36 2012 +0000

     Make "100e12" not parse as an Integer; part of #5688

 commit 4d849e6729d25ac4561d597b203c2af8757e6275
 Author: Ian Lynagh <[email protected]>
 Date:   Sun Mar 11 12:31:25 2012 +0000

     Avoid making huge Rational's when reading Double/Float; fixes #5688
 }}}

 We need to decide if we want to merge for 7.4.2. The arguments against
 doing so are:
  * Breaks the library interface policy, e.g. because the behaviour of
 `read "12e34" :: Integer` changes
  * Would mean we should bump base's version number to 4.6, which will mean
 lots of packages need updating.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5688#comment:56>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to