#7457: printf's * doesn't like negative numbers
Reporter:  elaforge          |          Owner:                  
    Type:  bug               |         Status:  new             
Priority:  normal            |      Component:  libraries/base  
 Version:  7.6.1             |       Keywords:                  
      Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
 Failure:  None/Unknown      |      Blockedby:                  
Blocking:                    |        Related:                  
 Text.Printf.printf has a bug where it doesn't like negative numbers for *

 Prelude Text.Printf> printf "%*sx\n" (-3) "hi"

 In the C printf, this would be
 hi x

 From looking at the source, it's a pretty easy bug to fix.  Patch
 attached.  I also included a patch to turn the mixed tabs and spaces into
 just spaces since I hate that stuff.

Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7457>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

Glasgow-haskell-bugs mailing list

Reply via email to