Re: [GHC] #2289: Needless reboxing of values when returning from a tight loop

2009-04-14 Thread GHC
#2289: Needless reboxing of values when returning from a tight loop ---+ Reporter: dons|Owner: Type: run-time performance bug| Status: new

Re: [GHC] #1600: Optimisation: CPR the results of IO

2009-04-14 Thread GHC
#1600: Optimisation: CPR the results of IO -+-- Reporter: simonmar |Owner: Type: task | Status: new Priority: normal|

Re: [GHC] #3008: Strange behavior when using newtyped version of IO monad in FFI import declarations

2009-04-14 Thread GHC
#3008: Strange behavior when using newtyped version of IO monad in FFI import declarations ---+ Reporter: waern |Owner: Type: bug | Status: new Priority:

Re: [GHC] #1544: Derived Read instances for recursive datatypes with infix constructors are too inefficient

2009-04-14 Thread GHC
#1544: Derived Read instances for recursive datatypes with infix constructors are too inefficient -+-- Reporter: jcpetru...@gmail.com |Owner: Type: bug |

Re: [GHC] #2765: unsetenv not found under Solaris 8 when building ghc-6.10.1

2009-04-14 Thread GHC
#2765: unsetenv not found under Solaris 8 when building ghc-6.10.1 -+-- Reporter: maeder|Owner: Type: bug | Status: new Priority: normal|Milestone: 6.12.1

Re: [GHC] #3163: GADTs should not allow polymorphism in return type

2009-04-14 Thread GHC
#3163: GADTs should not allow polymorphism in return type +--- Reporter: Scott Turner |Owner: Type: bug | Status: new Priority: normal

Re: [GHC] #3168: Unhelpful error message about hidden packages

2009-04-14 Thread GHC
#3168: Unhelpful error message about hidden packages -+-- Reporter: simonpj |Owner: Type: bug | Status: new Priority: normal|

Re: [GHC] #1544: Derived Read instances for recursive datatypes with infix constructors are too inefficient

2009-04-14 Thread GHC
#1544: Derived Read instances for recursive datatypes with infix constructors are too inefficient -+-- Reporter: jcpetru...@gmail.com |Owner: Type: bug |

Re: [GHC] #3168: Unhelpful error message about hidden packages

2009-04-14 Thread GHC
#3168: Unhelpful error message about hidden packages -+-- Reporter: simonpj |Owner: Type: bug | Status: new Priority: normal|

Re: [GHC] #3160: No exception safety in Control.Concurrent.QSem QSemN and SampleVar

2009-04-14 Thread GHC
#3160: No exception safety in Control.Concurrent.QSem QSemN and SampleVar -+-- Reporter: ChrisKuklewicz|Owner: Type: bug | Status: new Priority:

[GHC] #3168: Unhelpful error message about hidden packages

2009-04-14 Thread GHC
#3168: Unhelpful error message about hidden packages ---+ Reporter: simonpj | Owner: Type: bug | Status: new Priority: normal|

Re: [GHC] #3016: Long compile times, large memory use with static data in 6.10

2009-04-14 Thread GHC
#3016: Long compile times, large memory use with static data in 6.10 ---+ Reporter: dons|Owner: igloo Type: bug | Status: new

[GHC] #3169: Type families occurs check

2009-04-14 Thread GHC
#3169: Type families occurs check ---+ Reporter: simonpj | Owner: chak Type: bug | Status: new Priority: normal| Milestone:

Re: [GHC] #1962: make binary-dist creates nested directories under solaris

2009-04-14 Thread GHC
#1962: make binary-dist creates nested directories under solaris -+-- Reporter: maeder|Owner: Type: bug | Status: new Priority: normal|Milestone:

Re: [GHC] #1962: make binary-dist creates nested directories under solaris

2009-04-14 Thread GHC
#1962: make binary-dist creates nested directories under solaris -+-- Reporter: maeder|Owner: Type: bug | Status: closed Priority: normal|Milestone:

Re: [GHC] #2765: unsetenv not found under Solaris 8 when building ghc-6.10.1

2009-04-14 Thread GHC
#2765: unsetenv not found under Solaris 8 when building ghc-6.10.1 -+-- Reporter: maeder|Owner: Type: bug | Status: closed Priority: normal|Milestone: 6.12.1

Re: [GHC] #2349: SIZET_FMT in includes/mkDerivedConstants.c needs to be d under older Solaris version

2009-04-14 Thread GHC
#2349: SIZET_FMT in includes/mkDerivedConstants.c needs to be d under older Solaris version -+-- Reporter: maeder|Owner: Type: bug | Status: closed Priority: normal|

Re: [GHC] #2965: GHC on OS X does not compile 64-bit

2009-04-14 Thread GHC
#2965: GHC on OS X does not compile 64-bit +--- Reporter: Axman6 |Owner: thoughtpolice Type: feature request | Status: new Priority: normal |Milestone:

Re: [GHC] #2658: Extreme memory usage (probably type functions)

2009-04-14 Thread GHC
#2658: Extreme memory usage (probably type functions) +--- Reporter: guest|Owner: chak Type: bug | Status: closed Priority: low

[GHC] #3170: -fregs-graph: GraphOps.coalesceNodes: can't coalesce the same node.

2009-04-14 Thread GHC
#3170: -fregs-graph: GraphOps.coalesceNodes: can't coalesce the same node. ---+ Reporter: igloo | Owner: Type: bug | Status: new Priority:

Re: [GHC] #2790: Use -fregs-graph by default

2009-04-14 Thread GHC
#2790: Use -fregs-graph by default -+-- Reporter: igloo |Owner: Type: task | Status: new Priority: high |Milestone:

Re: [GHC] #3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages

2009-04-14 Thread GHC
#3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages ---+ Reporter: akrohit |Owner: Type: bug | Status: new Priority:

Re: [GHC] #3016: Long compile times, large memory use with static data in 6.10

2009-04-14 Thread GHC
#3016: Long compile times, large memory use with static data in 6.10 ---+ Reporter: dons|Owner: igloo Type: bug | Status: new

Re: [GHC] #3021: A way to programmatically insert marks into heap profiling output

2009-04-14 Thread GHC
#3021: A way to programmatically insert marks into heap profiling output -+-- Reporter: SamB |Owner: Type: feature request | Status: new Priority:

Re: [GHC] #3024: Rewrite hp2ps in Haskell

2009-04-14 Thread GHC
#3024: Rewrite hp2ps in Haskell -+-- Reporter: SamB |Owner: Type: task | Status: new Priority: normal|Milestone: 6.12

Re: [GHC] #3026: GHCi segfault

2009-04-14 Thread GHC
#3026: GHCi segfault ---+ Reporter: porges |Owner: Type: bug | Status: new Priority: normal |Milestone: Component: GHCi| Version: 6.10.1

Re: [GHC] #3026: GHCi segfault

2009-04-14 Thread GHC
#3026: GHCi segfault ---+ Reporter: porges |Owner: Type: bug | Status: new Priority: normal |Milestone: 6.12.1 Component: GHCi| Version: 6.10.1

Re: [GHC] #3030: GHCI Loading Compiled Modules Under Windows XP Crashes

2009-04-14 Thread GHC
#3030: GHCI Loading Compiled Modules Under Windows XP Crashes ---+ Reporter: jburck |Owner: Type: bug | Status: closed Priority: normal |Milestone: Component:

Re: [GHC] #3034: divInt# floated into a position which leads to low arity

2009-04-14 Thread GHC
#3034: divInt# floated into a position which leads to low arity -+-- Reporter: batterseapower|Owner: Type: run-time performance bug | Status: new

Re: [GHC] #3032: would be nice if -fno-code and --make worked together

2009-04-14 Thread GHC
#3032: would be nice if -fno-code and --make worked together -+-- Reporter: duncan|Owner: Type: feature request | Status: new Priority: normal

Re: [GHC] #1884: Win64 Port

2009-04-14 Thread GHC
#1884: Win64 Port ---+ Reporter: simonmar|Owner: Type: task| Status: new Priority: normal |Milestone: 6.12.1 Component: Compiler|

Re: [GHC] #3036: Max/Min Monoids

2009-04-14 Thread GHC
#3036: Max/Min Monoids -+-- Reporter: whpearson |Owner: Type: proposal | Status: new Priority: normal|Milestone: Not GHC

Re: [GHC] #3041: Arch independent binary representations

2009-04-14 Thread GHC
#3041: Arch independent binary representations -+-- Reporter: nomeata |Owner: Type: feature request | Status: new Priority: normal|Milestone: 6.12.1

Re: [GHC] #3045: GHCI Crashes Under Windows when loading compiled code

2009-04-14 Thread GHC
#3045: GHCI Crashes Under Windows when loading compiled code -+-- Reporter: jburck|Owner: Type: bug | Status: new Priority: low |Milestone: 6.12.1

Re: [GHC] #3049: STM with data invariants crashes GHC

2009-04-14 Thread GHC
#3049: STM with data invariants crashes GHC -+-- Reporter: simonpj |Owner: Type: bug | Status: new Priority: normal|

Re: [GHC] #3050: parsec: bug in caret escape parsing

2009-04-14 Thread GHC
#3050: parsec: bug in caret escape parsing --+- Reporter: sof|Owner: Type: bug| Status: new Priority: normal |

Re: [GHC] #3051: Add product/sum/maximum/minimum specialisations for more atomic types

2009-04-14 Thread GHC
#3051: Add product/sum/maximum/minimum specialisations for more atomic types -+-- Reporter: thorkilnaur |Owner: Type: bug | Status: new

Re: [GHC] #3056: StrictAnal module naming issue

2009-04-14 Thread GHC
#3056: StrictAnal module naming issue -+-- Reporter: pumpkin |Owner: Type: proposal | Status: closed Priority: normal|Milestone:

Re: [GHC] #3058: Add a 'hex' function to the pretty printing

2009-04-14 Thread GHC
#3058: Add a 'hex' function to the pretty printing -+-- Reporter: TomMD |Owner: Type: proposal | Status: new

Re: [GHC] #3054: ghc crashes with unicode escape and literal character together

2009-04-14 Thread GHC
#3054: ghc crashes with unicode escape and literal character together -+-- Reporter: iamfishhead |Owner: Type: bug | Status: closed Priority: normal|

Re: [GHC] #3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages

2009-04-14 Thread GHC
#3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages ---+ Reporter: akrohit |Owner: Type: bug | Status: new Priority:

Re: [GHC] #3059: 3 different behaviours depending on profiling settings and on a used-only-once form being top-level

2009-04-14 Thread GHC
#3059: 3 different behaviours depending on profiling settings and on a used-only- once form being top-level -+-- Reporter: jkff |Owner: Type: bug | Status: new

Re: [GHC] #3064: Very long compile times with type functions

2009-04-14 Thread GHC
#3064: Very long compile times with type functions -+-- Reporter: simonpj |Owner: chak Type: compile-time performance bug | Status: new

Re: [GHC] #3070: floor(0/0) should not be defined

2009-04-14 Thread GHC
#3070: floor(0/0) should not be defined -+-- Reporter: carette |Owner: Type: bug | Status: new Priority: normal|

Re: [GHC] #3072: considerations for management of shared libs

2009-04-14 Thread GHC
#3072: considerations for management of shared libs -+-- Reporter: duncan|Owner: Type: proposal | Status: new Priority: normal|Milestone:

Re: [GHC] #3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages

2009-04-14 Thread GHC
#3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages ---+ Reporter: akrohit |Owner: Type: bug | Status: new Priority:

Re: [GHC] #3073: Avoid reconstructing dictionaries in recursive instance methods

2009-04-14 Thread GHC
#3073: Avoid reconstructing dictionaries in recursive instance methods -+-- Reporter: simonpj |Owner: Type: run-time performance bug | Status: new

Re: [GHC] #3076: Make genericLength tail-recursive so it doesn't overflow stack

2009-04-14 Thread GHC
#3076: Make genericLength tail-recursive so it doesn't overflow stack -+-- Reporter: Syzygies |Owner: Type: run-time performance bug | Status: closed

Re: [GHC] #3088: have ghc-pkg print less useless info when registering

2009-04-14 Thread GHC
#3088: have ghc-pkg print less useless info when registering -+-- Reporter: duncan|Owner: Type: feature request | Status: new Priority: normal

Re: [GHC] #1876: Complete shared library support

2009-04-14 Thread GHC
#1876: Complete shared library support -+-- Reporter: simonmar |Owner: Type: task | Status: new Priority: high |

Re: [GHC] #3163: GADTs should not allow polymorphism in return type

2009-04-14 Thread GHC
#3163: GADTs should not allow polymorphism in return type +--- Reporter: Scott Turner |Owner: Type: bug | Status: new Priority: normal

Re: [GHC] #3170: -fregs-graph: GraphOps.coalesceNodes: can't coalesce the same node.

2009-04-14 Thread GHC
#3170: -fregs-graph: GraphOps.coalesceNodes: can't coalesce the same node. -+-- Reporter: igloo |Owner: benl Type: bug | Status: assigned

Re: [GHC] #3169: Type families occurs check

2009-04-14 Thread GHC
#3169: Type families occurs check -+-- Reporter: simonpj |Owner: chak Type: bug | Status: closed Priority: normal|Milestone:

Re: [GHC] #3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages

2009-04-14 Thread GHC
#3015: Building packages using ghc (6.8.2) results in inconsistent error assembler messages ---+ Reporter: akrohit |Owner: Type: bug | Status: new Priority:

bootstrap openbsd powerpc - continues

2009-04-14 Thread Jake L
Okay, I worked through the .h issue(it was late at night), but wasn't able to make headway with 6.6.1(exception type ambiguities), so I switched platforms and downgraded to earlier versions: take 2 -- target = powerpc-unknown-openbsd host = i386-unknown-linux with a running ghc 6.4.2

RE: [Haskell] deriving Show for GADT?

2009-04-14 Thread Simon Peyton-Jones
Yes, indeed, see http://hackage.haskell.org/trac/ghc/ticket/3012 Incidentally, the main Haskell list isn't the right place for GHC-specific questions. glasgow-haskell-users@haskell.org is the place Simon | -Original Message- | From: haskell-boun...@haskell.org

Re: [Haskell] deriving Show for GADT?

2009-04-14 Thread Lennart Augustsson
If it's easy I think just generating the code and let the type checker report any problems would be a great thing for standalone deriving. -- Lennart On Tue, Apr 14, 2009 at 10:10 AM, Simon Peyton-Jones simo...@microsoft.com wrote: Yes, indeed, see

Re: failure implementing :next command in ghci

2009-04-14 Thread Peter Hercek
Hi, Pepe Iborra pointed out that my patch is not in the right format for gnu patch command. Sorry for inconvenience (I used darcs what -u instead of darcs diff -u). Here it is attached in the correct format. Thanks, Peter. diff -rN -u old-ghc/compiler/main/InteractiveEval.hs

Re: where is ghcautoconf.h, DerivedConstants.h and GHCConstants.h

2009-04-14 Thread Ian Lynagh
Hi Jake, On Mon, Apr 13, 2009 at 03:58:42AM -0400, Jake L wrote: following wiki to make an unregistered build of ghc 6.6.1 on openbsd-powerpc-current target= powerpc_unknown_openbsd host = x86_64_unknown_linux with ghc-6.10.2 You'll probably need to use 6.6.1 on the host.

Re: [Haskell] deriving Show for GADT?

2009-04-14 Thread Ryan Ingram
You might be able to write some Template Haskell to derive the Show instance. It's a bit tricky, because there are some types which can't have Show derived, such as: data Foo where Broken :: a - Foo What should show (Broken id) do? -- ryan On Mon, Apr 13, 2009 at 9:28 PM, Norman

[Haskell] CFP Trends in Functional Programming

2009-04-14 Thread Horváth Zoltán
Third call for papers 10th SYMPOSIUM ON TRENDS IN FUNCTIONAL PROGRAMMING TFP 2009 SELYE JANOS UNIVERSITY, KOMARNO, SLOVAKIA June 2-4, 2009 http://www.inf.elte.hu/tfp_cefp_2009 *** Submission deadline extended until 10th of May! *** The symposium on Trends in Functional Programming (TFP) is

[Haskell] The Monad.Reader (14) - Call for copy

2009-04-14 Thread Wouter Swierstra
Call for Copy The Monad.Reader - Issue 14 Please consider writing something for the next issue of The Monad.Reader. The deadline for Issue 14 is: ** May 15, 2009 ** The Monad.Reader is a electronic magazine about all things

Re: [Haskell] CFP Trends in Functional Programming

2009-04-14 Thread Wolfgang Jeltsch
Am Dienstag, 14. April 2009 12:55 schrieb Horváth Zoltán: Third call for papers 10th SYMPOSIUM ON TRENDS IN FUNCTIONAL PROGRAMMING TFP 2009 SELYE JANOS UNIVERSITY, KOMARNO, SLOVAKIA June 2-4, 2009 http://www.inf.elte.hu/tfp_cefp_2009 *** Submission deadline extended until 10th of May!

Re: [Haskell] deriving Show for GADT?

2009-04-14 Thread Edward Kmett
I seem to recall Matt Morrow having some code lying around for automatically generating such instances using haskell-src-exts. I wonder how hard it would be to adapt to Template Haskell. -Edward Kmett On Tue, Apr 14, 2009 at 2:03 AM, Ryan Ingram ryani.s...@gmail.com wrote: You might be able to

[Haskell] Re: deriving Show for GADT?

2009-04-14 Thread Dominic Steinitz
Norman Ramsey nr at cs.tufts.edu writes: I've got a fairly large GADT for which I wished to use deriving (Show) You will have to write one by hand. I tend to use Text.Pretty and then the output is much more readable. It doesn't take long even for a what I would consider a large GADT.

[Haskell] Haskell logo in TeX (tested for TeXLive = 2007)

2009-04-14 Thread Philip Hölzenspies
Dear all, Seeing people throw the new logo around in different formats, I thought I would do it up in TikZ (for those that don't know: graphics embedded in LaTeX). For convenience, I wrapped it in a .sty file. If people find this useful, I will try and submit it to CTAN as well. I'm open

Re: [Haskell] Haskell logo in TeX (tested for TeXLive = 2007)

2009-04-14 Thread Benjamin Perez
wow!! is great. thanks, -- Benjo On Tue, 2009-04-14 at 22:05 +0200, Philip Hölzenspies wrote: Dear all, Seeing people throw the new logo around in different formats, I thought I would do it up in TikZ (for those that don't know: graphics embedded in LaTeX). For convenience, I wrapped it

[Haskell-cafe] Re: Maybe off-topic -- Writing contracts or software specifications

2009-04-14 Thread Achim Schneider
Richard O'Keefe o...@cs.otago.ac.nz wrote: If you have a low level of trust, you'll need a great level of detail, and it still won't help. Heh. Keep your friends close, your enemies closer. Freelancing, I was always paid per hour, not per feature. From my experience, writing something like

Re: [Haskell-cafe] How the following works

2009-04-14 Thread Lennart Augustsson
Assuming you already think you know what cinits does, you can convince yourself using induction. On Tue, Apr 14, 2009 at 11:16 AM, Tsunkiet Man temp.t...@gmail.com wrote: Let's see, if I execute it by hand: cinits :: [a] - [[a]] cinits [] = [[]] cinits (x:xs) = [] : map (x:) (cinits xs)

Re: [Haskell-cafe] ANN: Elerea, another FRP library

2009-04-14 Thread Patai Gergely
And just as IO is unnecessary for behavior (functions of time), it's also unnecessary for imagery (functions of space). Continuing with the functional (non-IO) theme, you can give a semantically precise, composable and simple type of images. Yes, that's a further separation of concerns.

[Haskell-cafe] Re: Best text editor

2009-04-14 Thread Achim Schneider
FFT fft1...@gmail.com wrote: Has anyone tried Yi? Yes, and I figured I'd have to edit the keymap to get productive. While it features a fully functional subset of vim that's more than enough to efficiently edit files, it's not the subset I use... and then I was too lazy to actually do it.

Re[2]: [Haskell-cafe] Best text editor

2009-04-14 Thread Bulat Ziganshin
Hello Alexandr, Tuesday, April 14, 2009, 6:37:38 AM, you wrote: Hi I would like to follow the crowd and find out what text editor everyone uses for haskell on windows. * HippoEdit (http://www.hippoedit.com/) i've tried HippoEdit and don't recommend it. it's work in progress so i

Re: [Haskell-cafe] ANN: Elerea, another FRP library

2009-04-14 Thread Patai Gergely
Interesting. I'm testing it on Window though. You're using Linux? Maybe the scheduling is different. Now I tried it on Windows in VirtualBox, and it still looks quite smooth to me (except that hardware acceleration doesn't seem to work properly through virtualisation, but it's okay as long as I

[Haskell-cafe] Re: Best text editor

2009-04-14 Thread Achim Schneider
Melanie_Green jac_legend_...@hotmail.com wrote: Hi I would like to follow the crowd and find out what text editor everyone uses for haskell on windows. Have you considered using leksah? While it doesn't focus on being an editor, it's still a darn fine way to edit Haskell. -- (c) this sig

Re: [Haskell-cafe] How the following works

2009-04-14 Thread Tsunkiet Man
Let's see, if I execute it by hand: cinits :: [a] - [[a]] cinits [] = [[]] cinits (x:xs) = [] : map (x:) (cinits xs) cinits [1,2,3] = [] : map (1:) ( [] : map (2:) ( [] : map (3:) ( [[]]) ) ) = [] : map (1:) ( [] : map (2:) ( [] : map (3:) [[]] ) ) = [] :

[Haskell-cafe] Non-atomic atoms for type-level programming

2009-04-14 Thread Claus Reinke
The recent GHC trac ticket revision reminded me of the old open type-sharing problem with type tags and record labels: - if type-level tags (such as 'data TTrue'/'data TFalse') are declared repeatedly in separate modules, they represent separate types, preventing shared use (your

Re: [Haskell-cafe] Types and hashes of hashes, trouble for a Java-programmer...

2009-04-14 Thread John Smith
Thanks, I was close, but the I was trying to use (something like) this statement without the return: maybe (return Nothing) (flip HashTable.lookup 1000) More or less like this: maybe (Nothing) (flip HashTable.lookup 1000) Which did't work... Guess the return is needed because we use a new monad

Re: [Haskell-cafe] How the following works

2009-04-14 Thread Daniel Fischer
Am Dienstag 14 April 2009 10:39:28 schrieb Tsunkiet Man: Hello, I can hardly imagine how the following code works: cinits :: [a] - [[a]] cinits [] = [[]] cinits (x:xs) = [] : map (x:) (cinits xs) can someone give me a good explaination? Perhaps it's easier to follow as a list

[Haskell-cafe] Looking for the fastest Haskell primes algorithm

2009-04-14 Thread Niemeijer, R.A.
Today I happened to need a large list of prime numbers. Obviously this is a well-known problem, so I figured there would be something on Hackage that I could use. Surprisingly, there isn't, or if there is it's not easy to find. Searching for prime or primes on Hackage reveals nothing. Searching

Re: [Haskell-cafe] Looking for the fastest Haskell primes algorithm

2009-04-14 Thread Andrew Wagner
Some other ideas for things to put in this package possibly: is_prime :: Int - Bool nth_prime :: Int - Int -- or Int - Integer prime_factors :: Int - [Int] I'm assuming there are faster ways of doing the first 2 than by just simply looking through all of primes. Someone should also look through

Re: [Haskell-cafe] Looking for the fastest Haskell primes algorithm

2009-04-14 Thread Eugene Kirpichov
I'd suggest also primesFrom :: Integer - [Integer] and probably a separate function nextPrime :: Integer - Integer 2009/4/14 Andrew Wagner wagner.and...@gmail.com: Some other ideas for things to put in this package possibly: is_prime :: Int - Bool nth_prime :: Int - Int -- or Int - Integer

Re: [Haskell-cafe] Best text editor

2009-04-14 Thread Juan Pedro Bolivar Puente
and Visual Haskell had some unique features (such as hovering tooltips showing types) that are now found in the F# editor, and should now be easier to implement with the recent GHC API (I guess). haskell-mode for Emacs does show the type signature of standard functions in the mini-buffer when

[Haskell-cafe] The Monad.Reader (14) - Call for copy

2009-04-14 Thread Wouter Swierstra
Call for Copy The Monad.Reader - Issue 14 Please consider writing something for the next issue of The Monad.Reader. The deadline for Issue 14 is: ** May 15, 2009 ** The Monad.Reader is a electronic magazine about all things

Re: [Haskell-cafe] Looking for the fastest Haskell primes algorithm

2009-04-14 Thread Martijn van Steenbergen
Niemeijer, R.A. wrote: Since it’s such a common problem I’d say it would be a good idea to add a package to Hackage that exports primes :: [Integer] and hides the ugly implementation details. Data.Numbers.Primes seems a logical choice for the namespace, but I’m open to suggestions.

Re: [Haskell-cafe] Looking for the fastest Haskell primes algorithm

2009-04-14 Thread Edward Kmett
You might want to start with the Sieve of Atkin: http://en.wikipedia.org/wiki/Sieve_of_Atkin -Edward On Tue, Apr 14, 2009 at 8:40 AM, Niemeijer, R.A. r.a.niemei...@tue.nlwrote: Today I happened to need a large list of prime numbers. Obviously this is a well-known problem, so I figured there

Re: [Haskell-cafe] ANN: hmatrix-static: statically-sized linear algebra

2009-04-14 Thread Alberto Ruiz
Hi Reiner, Fantastic work! User-friendly static dimension checking is an essential feature for any decent linear algebra library. Your interface using quasiquotation and view patterns is very elegant and practical. I am happy that hmatrix is useful, but I'm afraid that its primitive dynamic

[Haskell-cafe] Printing list of enum type

2009-04-14 Thread michael rice
What do I need to add to this Color enum type to print a list of them? Michael === data Color     = Red     | Blue     | Green     | Yellow     | Orange     | Brown     | White     | Black instance Show Color where     show Red   = Red     show Blue  = Blue     show

Re: [Haskell-cafe] Printing list of enum type

2009-04-14 Thread Eugene Kirpichov
1. data Color = Red | Green | Blue deriving (Show) 2. [Red,Black,White] 2009/4/14 michael rice nowg...@yahoo.com: What do I need to add to this Color enum type to print a list of them? Michael === data Color     = Red     | Blue     | Green     | Yellow     | Orange     |

Re: [Haskell-cafe] Printing list of enum type

2009-04-14 Thread michael rice
Dumb, dumb, dumb, dumb, DUMB!, he Lisped. Thanks. Michael --- On Tue, 4/14/09, Andrew Wagner wagner.and...@gmail.com wrote: From: Andrew Wagner wagner.and...@gmail.com Subject: Re: [Haskell-cafe] Printing list of enum type To: michael rice nowg...@yahoo.com Cc: haskell-cafe@haskell.org Date:

Re: [Haskell-cafe] ANN: Elerea, another FRP library

2009-04-14 Thread Wolfgang Jeltsch
Am Freitag, 10. April 2009 18:41 schrieb Patai Gergely: is based on some unsafePerformIO dark magic (that might easily break depending on many factors) I wonder if this breaks referential transparency. Say, you define a signal s and use s twice in some expression. s may be evaluated once and

Re: [Haskell-cafe] ANN: Elerea, another FRP library

2009-04-14 Thread Wolfgang Jeltsch
Am Dienstag, 14. April 2009 11:33 schrieb Patai Gergely: and then the integration of a Grapefruit-like and a Reactive-like system could be the ultimate solution in the long run. What do you think, Grapefruit is lacking, compared to Reactive? Best wishes, Wolfgang

[Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread rodrigo.bonifacio
Dear Sirs, I guess this is a very simple question. How can I convert IO [XmlTree] to just a list of XmlTree? Regards, Rodrigo.   ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Luke Palmer
On Tue, Apr 14, 2009 at 8:54 AM, rodrigo.bonifacio rodrigo.bonifa...@uol.com.br wrote: Dear Sirs, I guess this is a very simple question. How can I convert IO [XmlTree] to just a list of XmlTree? This is very important: you cannot. But you can still get your hands on one inside a do block.

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Alex Queiroz
Hallo, On 4/14/09, rodrigo.bonifacio rodrigo.bonifa...@uol.com.br wrote: Dear Sirs, I guess this is a very simple question. How can I convert IO [XmlTree] to just a list of XmlTree? The short answer is: You cannot. The longer answer is: Only put things in the IO monad when you need

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Cristiano Paris
On Tue, Apr 14, 2009 at 4:54 PM, rodrigo.bonifacio rodrigo.bonifa...@uol.com.br wrote: Dear Sirs, I guess this is a very simple question. How can I convert IO [XmlTree] to just a list of XmlTree? Quick and dirty answer: unsafePerformIO. That's an easy finding on Hoogle:

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Cristiano Paris
On Tue, Apr 14, 2009 at 5:01 PM, Luke Palmer lrpal...@gmail.com wrote: ... This is very important: you cannot. I'd answer You shouldn't, unless you know what you are doing. In some cases, not only is unsafePerformIO desirable but also necessary (I'm thinking of Debug.Trace). Cristiano

Re: [Haskell-cafe] ANN: Elerea, another FRP library

2009-04-14 Thread Wolfgang Jeltsch
Am Samstag, 11. April 2009 16:57 schrieb Patai Gergely: Any idea how Elerea compares to Grapefruit? It's great to see a lot of competition in the FRP arena, but I hope in the end this results in a really usable and scalable FRP system for Haskell :-) I think Wolfgang can judge this better,

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Luke Palmer
On Tue, Apr 14, 2009 at 9:01 AM, Cristiano Paris fr...@theshire.org wrote: On Tue, Apr 14, 2009 at 4:54 PM, rodrigo.bonifacio rodrigo.bonifa...@uol.com.br wrote: Dear Sirs, I guess this is a very simple question. How can I convert IO [XmlTree] to just a list of XmlTree? Quick and

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread Andrew Wagner
Here's another way of looking at what others have already said. The only way you can do that is within the scope of another IO action. For example: outputXmlTrees :: IO () outputXmlTrees = do trees - inputXmlTrees; let newTrees = transform trees; print . show $ newTrees Notice a few things:

Re: [Haskell-cafe] Converting IO [XmlTree] to [XmlTree]

2009-04-14 Thread John Van Enk
Quick and dirty answer: unsafePerformIO. You can do a lot of cool things with a table saw if you take the blade guard off. On Tue, Apr 14, 2009 at 11:01 AM, Cristiano Paris fr...@theshire.orgwrote: On Tue, Apr 14, 2009 at 4:54 PM, rodrigo.bonifacio rodrigo.bonifa...@uol.com.br wrote: Dear

  1   2   >