[Haskell-beginners] Why does this work in a program, but cause a
seg fault in ghci?
Sebastián E. Peyrott
pseus7 at gmail.com
Tue Aug 10 22:59:28 EDT 2010
AFAIK, that should never happen. The expression looks sane, too, so I
guess it's a bug in GHCi. 6.10.4 is not the latest stable version of
GHC, so you might want to update it.
On Tue, Aug 10, 2010 at 11:51 PM, Kurt Häusler <kurt.haeusler at gmail.com> wrote:
> I am going through the OpenGL tutorial 1 (http://www.haskell.org/haskellwiki/OpenGLTutorial1)
> The first example program in chapter 2 works if I compile it and run it, but I don't understand all of it so I am playing with bits of it in ghci. Look what happens:
> GHCi, version 6.10.4: http://www.haskell.org/ghc/ :? for help
> Loading package ghc-prim ... linking ... done.
> Loading package integer ... linking ... done.
> Loading package base ... linking ... done.
> Prelude> let myPoints = map (\k -> (sin(2*pi*k/12),cos(2*pi*k/12),0.0)) [1..12]
> Prelude> myPoints
> [(0.49999999999999994,0.8660254037844387,0.0),(0.8660254037844386,0.5000000000000001,0.0),(1.0,6.123233995736766e-17,0.0),(0.8660254037844388,-Segmentation fault
> Any ideas?
> Beginners mailing list
> Beginners at haskell.org
More information about the Beginners