#1622: Haskell program's standard output breaks down if piped through 'more'
----------------------------------------+-----------------------------------
  Reporter:  [EMAIL PROTECTED]  |          Owner:       
      Type:  bug                        |         Status:  new  
  Priority:  normal                     |      Milestone:       
 Component:  Compiler                   |        Version:  6.4.1
  Severity:  normal                     |       Keywords:       
Difficulty:  Unknown                    |             Os:  Linux
  Testcase:                             |   Architecture:  x86  
----------------------------------------+-----------------------------------
In earlier versions of GHC (up to 6.2 I remember) I could easily pipe
 stdout of Haskell programs through other Shell programs. But now various
 applications fail, especially piping through 'more'. ('less' makes no
 problems.)

 {{{
 $ ghci
 ...
 Prelude> :! ls -al /usr/lib/ghc-6.4.1/ | more
 insgesamt 88869
 drwxr-xr-x    6 root root     2880 2006-09-03 12:13 .
 drwxr-xr-x  111 root root    35200 2006-10-28 18:21 ..
 -rwxr-xr-x    1 root root    42808 2005-09-19 14:48 cgprof
 -rwxr-xr-x    1 root root  8701804 2005-09-19 14:48 ghc-6.4.1
 -rwxr-xr-x    1 root root    58773 2005-09-19 14:45 ghc-asm
 -rw-r--r--    1 root root      807 2005-09-19 14:45 ghci-usage.txt
 -rwxr-xr-x    1 root root   847628 2005-09-19 14:48 ghc-pkg.bin
 -rwxr-xr-x    1 root root    16886 2005-09-19 14:45 ghc-split
 -rw-r--r--    1 root root     2755 2005-09-19 14:45 ghc-usage.txt
 -rw-r--r--    1 root root    72960 2005-09-19 14:45 HSbase_cbits.o
 -rw-r--r--    1 root root  4887418 2005-09-19 14:45 HSbase.o
 -rwxr-xr-x    1 root root   538124 2005-09-19 14:48 hsc2hs-bin
 -rw-r--r--    1 root root  1381745 2005-09-19 14:45 HSCabal.o
 -rw-r--r--    1 root root    29942 2005-09-19 14:46 HSconcurrent.o
 -rw-r--r--    1 root root  1188121 2005-09-19 14:46 HSdata.o
 -rw-r--r--    1 root root   493422 2005-09-19 14:46 HSfgl.o
 -rw-r--r--    1 root root     1516 2005-09-19 14:46 HSGLUT_cbits.o
 -rw-r--r--    1 root root   673936 2005-09-19 14:46 HSGLUT.o
 -rw-r--r--    1 root root     8539 2005-09-19 14:45 HShaskell98.o
 -rw-r--r--    1 root root  1875175 2005-09-19 14:45 HShaskell-src.o
 -rw-r--r--    1 root root   337126 2005-09-19 14:46 HSHGL.o
 Prelude>
 }}}

 There are much more files after HSHGL.o,
 but instead of the 'more?' prompt, the command stops.


 {{{
 ~/haskell/htam$ ./Setup.lhs build 2>&1 | more
 Preprocessing library HTam-0.0...
 Preprocessing executables for HTam-0.0...
 Building HTam-0.0...
 Chasing modules from:
 ArbitraryRatio,Combinatorics,Combinatorics.BellNumbers,Com
 
binatorics.Partitions,Combinatorics.TreeDepth,ContinuedFraction,DiscretizedFunct
 
ion,BinaryCards,Election,Fractal,Resistor,RndBox,StableMarriage,Digits,Recursive
 
Expression,SymbolicDifferentation,GNUPlot,ImageProcessing.PortableAnyMap,ImagePr
 
ocessing.SubpixelAntialiasing,Interpolation.CubicSpline,Interpolation.DividedDif
 
ference,Interpolation.NewtonPolynomial,Card,Cardinal,PeanoNumber,UnlimitedPrecis
 
ion,NumberTheory,Numerics.DglEuler,Numerics.Differentiation,Numerics.Fourier,Num
 
erics.Function,Numerics.Integration,Numerics.Mean,Numerics.Newton,Numerics.Norm,
 
Numerics.ODEEuler,Numerics.PiPolygonal,Numerics.RegulaFalsi,Numerics.Root,Numeri
 
cs.SecantMethod,Numerics.SpecialFunctions,Numerics.SpecialFunctionsSimple,Polyno
 
mial,ArithSumSquare,DiceVanish,DistributedDots,Equation,NumberCircle,Owl,Periodi
 cSequence,SquarePair,SudokuWiki,Stochastic,CDFLifting,Useful
 Skipping  Useful           ( src/Useful.hs, dist/build/Useful.o )
 Skipping  Stochastic       ( src/Stochastic.hs, dist/build/Stochastic.o )
 Skipping  SudokuWiki       ( src/Riddle/SudokuWiki.hs,
 dist/build/SudokuWiki.o )
 Skipping  SquarePair       ( src/Riddle/SquarePair.hs,
 dist/build/SquarePair.o )
 Skipping  DistributedDots  ( src/Riddle/DistributedDots.hs,
 dist/build/Distribut
 edDots.o )
 Skipping  DiceVanish       ( src/Riddle/DiceVanish.hs,
 dist/build/DiceVanish.o )
 ~/haskell/htam$
 }}}

 There are much more modules after DiceVanish, but the output stops
 silently.


 {{{
 ~/haskell/htam$ darcs changes | more
 Sat Jul 29 14:27:34 CEST 2006  [EMAIL PROTECTED]
   * BinaryCards: latex output

 Tue Jun 20 16:50:46 CEST 2006  [EMAIL PROTECTED]
   * new module Numerics.Mean various means

 Wed Jun  7 19:20:38 CEST 2006  [EMAIL PROTECTED]
   * Setup: use Cabal's rawSystemVerbose instead of System.Cmd.rawSystem

 Wed Jun  7 19:18:23 CEST 2006  [EMAIL PROTECTED]
   * SquarePairs: added new solution based on List monad

 Wed Jun  7 19:17:44 CEST 2006  [EMAIL PROTECTED]
   * Useful: new iterateLimitM

 Sun Jun  4 17:05:25 CEST 2006  [EMAIL PROTECTED]
   * Useful: splitLast added

 Sun Jun  4 17:04:55 CEST 2006  [EMAIL PROTECTED]
   * Card, Cardinal: removed unnecessary checks for negativity

 Sun Jun  4 17:03:51 CEST 2006  [EMAIL PROTECTED]
 ~/haskell/htam$
 }}}

 There are much more patches, but the output stops silently, again.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1622>
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