[Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Ketil Malde
I've rather recently started to use cabal-install to install packages from Hackage. Unfortunately, so far many packages fail to install. I try to email authors/maintainers, but when I check build logs on Hackage, I discover that some of these packages have failed building for some time.

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Christopher Done
That sounds like a good idea. I'd like to know when my packages fail to build or show warnings about deprecated features, etc. On 22 July 2010 09:16, Ketil Malde ke...@malde.org wrote: I've rather recently started to use cabal-install to install packages from Hackage.  Unfortunately, so far

Re: [Haskell-cafe] Porting ELF statifier to Haskell!

2010-07-22 Thread Thomas DuBuisson
Interesting tool. For my recent work I too have found a use for the elf package, but its lack of a full binary instance and no parsing of .symtab or .dynstr sections limits its usefulness. This isn't a debilitating limitation - you can use elf for basic inspection then perform mutations via

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Isak Hansen
On Thu, Jul 22, 2010 at 9:16 AM, Ketil Malde ke...@malde.org wrote: I've rather recently started to use cabal-install to install packages from Hackage. Unfortunately, so far many packages fail to install. I try to email authors/maintainers, but when I check build logs on Hackage, I discover

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Christopher Done
I don't know how wise that is; I tend to fix packages when I find they're broken. I'd prefer a way for there to be more than one maintainer for a package, i.e., collaborators, like on Github, so that a maintainer can add me as a collaborator. My only problem with Hackage is I feel like the

Re: [Haskell-cafe] On documentation

2010-07-22 Thread David Waern
2010/7/21 Richard O'Keefe o...@cs.otago.ac.nz: One of the really nice ideas in the R statistics system is that documentation pages can contain executable examples, and when you wrap up a package for distribution, the system checks that the examples run as advertised. The next version of

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Magnus Therning
On Wed, Jul 21, 2010 at 17:43, Rogan Creswick cresw...@gmail.com wrote: On Wed, Jul 21, 2010 at 3:00 AM, Magnus Therning mag...@therning.org wrote: I am successfully using hooks with the following in my .cabal file:    Build-Type    : Simple and my main in Setup.hs looks like this:    

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Malcolm Wallace
My only problem with Hackage is I feel like the maintainer is a fence I have to climb every time I want to upload a bugfix or a non-broken version of the package. I just want to fix it, upload it, and continue with my work. Unfortunately, experience shows that a gatekeeper is usually

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Magnus Therning
On Thu, Jul 22, 2010 at 10:02, Malcolm Wallace malcolm.wall...@me.com wrote: My only problem with Hackage is I feel like the maintainer is a fence I have to climb every time I want to upload a bugfix or a non-broken version of the package. I just want to fix it, upload it, and continue with my

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Ross Paterson
On Wed, Jul 21, 2010 at 09:43:16AM -0700, Rogan Creswick wrote: On Wed, Jul 21, 2010 at 3:00 AM, Magnus Therning mag...@therning.org wrote: I am successfully using hooks with the following in my .cabal file:    Build-Type    : Simple I've been unable to reproduce this -- flipping the

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Magnus Therning
On Thu, Jul 22, 2010 at 10:59, Ross Paterson r...@soi.city.ac.uk wrote: On Wed, Jul 21, 2010 at 09:43:16AM -0700, Rogan Creswick wrote: On Wed, Jul 21, 2010 at 3:00 AM, Magnus Therning mag...@therning.org wrote: I am successfully using hooks with the following in my .cabal file:    

Re: [Haskell-cafe] On documentation

2010-07-22 Thread wren ng thornton
David Waern wrote: 2010/7/21 Richard O'Keefe o...@cs.otago.ac.nz: One of the really nice ideas in the R statistics system is that documentation pages can contain executable examples, and when you wrap up a package for distribution, the system checks that the examples run as advertised. The

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Ross Paterson
On Thu, Jul 22, 2010 at 11:31:21AM +0100, Magnus Therning wrote: On Thu, Jul 22, 2010 at 10:59, Ross Paterson r...@soi.city.ac.uk wrote: Magnus is building by directly running the Setup.hs himself, which ignores the Build-Type.  To get cabal-install to use his Setup.hs, the Build-Type must

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Magnus Therning
On Thu, Jul 22, 2010 at 11:52, Ross Paterson r...@soi.city.ac.uk wrote: On Thu, Jul 22, 2010 at 11:31:21AM +0100, Magnus Therning wrote: On Thu, Jul 22, 2010 at 10:59, Ross Paterson r...@soi.city.ac.uk wrote: Magnus is building by directly running the Setup.hs himself, which ignores the

[Haskell-cafe] Page rank and GHC docs directory organization

2010-07-22 Thread Ryan Newton
GHC docs seem to have the problem that newer versions only gradually overtake older ones in page rank, resulting in the effect that if one uses Google to find library documentation, they may accidentally look at an old version. For example, if I google Data.Data Haskell the first link brings me

Re: [Haskell-cafe] Page rank and GHC docs directory organization

2010-07-22 Thread Robin KAY
On 22/07/10 15:33, Ryan Newton wrote: [snip] So is the 6.12.2 target accruing pagerank rather than the latest one? Even if someone links the /latest/ URL? If that's the problem, would it fix things just to make latest/ a full directory structure in its own right (a clone rather than redirect)?

Re: [Haskell-cafe] Porting ELF statifier to Haskell!

2010-07-22 Thread C K Kashyap
Thanks Thomas. On Thu, Jul 22, 2010 at 12:56 PM, Thomas DuBuisson thomas.dubuis...@gmail.com wrote: Interesting tool. For my recent work I too have found a use for the elf package, but its lack of a full binary instance and no parsing of .symtab or .dynstr sections limits its usefulness.

Re: [Haskell-cafe] Page rank and GHC docs directory organization

2010-07-22 Thread Johan Tibell
On Thu, Jul 22, 2010 at 4:33 PM, Ryan Newton rrnew...@gmail.com wrote: GHC docs seem to have the problem that newer versions only gradually overtake older ones in page rank, resulting in the effect that if one uses Google to find library documentation, they may accidentally look at an old

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Thomas DuBuisson
Not to discourage this brainstorming, but many of what people think to be new ideas are being implemented by a GsoC student [1] already. Yay! I've rather recently started to use cabal-install to install packages from Hackage.  Unfortunately, so far many packages fail to install.  I try to

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Stephen Tetley
On 22 July 2010 16:56, Thomas DuBuisson thomas.dubuis...@gmail.com wrote: The hackage build logs can be misleading - many system specific packages may or may not build on hackage because it just isn't the right OS.  Still other packages require particular C libraries that the hackage server

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Daniel Fischer
On Thursday 22 July 2010 18:23:32, Stephen Tetley wrote: On 22 July 2010 16:56, Thomas DuBuisson thomas.dubuis...@gmail.com wrote: The hackage build logs can be misleading - many system specific packages may or may not build on hackage because it just isn't the right OS.  Still other

Re: [Haskell-cafe] On documentation

2010-07-22 Thread Andrew Coppin
Alexander Solla wrote: After all, the source is always structured in more-or-less the same way. Fragments of text with opaque -- unless/until you understand them -- combinators join two distinct concepts/types into functions. A chain of functions (potentially at various levels of

[Haskell-cafe] Regular Expression to Determinate Finite Automata translator

2010-07-22 Thread Aaron Gray
Hi, I am a Haskell newbie. I have coded a Regular Expression to Determinate Finite Automata translator. Algorithm from the Dragon Book. Would someone eyeball the code and give me suggestions please. I have not done anything on character classes yet though. And the parsing is a bit of a hack.

Re: [Haskell-cafe] Regular Expression to Determinate Finite Automata translator

2010-07-22 Thread Felipe Lessa
Some comments: - You can run your code thru HLint, here it gives me 27 suggestions. - Why don't you derive the Show instance for RE instead of writing it by yourself? - Note that do x do y ... is the same as do x y ... - You can parametrize RE as data RE s p =

Re: [Haskell-cafe] Regular Expression to Determinate Finite Automata translator

2010-07-22 Thread S. Doaitse Swierstra
The simplest way to make a recogniser out of a RE is to use one of the available parsing libraries: module RE where import Text.ParserCombinators.UU import Text.ParserCombinators.UU.Examples data RE = Epsilon | Leaf Char | Selection RE RE | Sequence RE RE | Kleene RE | Optional RE | End

[Haskell-cafe] bounded ranges

2010-07-22 Thread Chad Scherrer
Hello cafe, I'm trying to do some things with bounded indices so I can carry around arrays (well, Vectors, really) without needing to refer to the bounds. For example, if I know my indices are Bool values, I can do rangeSize (minBound, maxBound :: Bool) 2 I'd like to be able to do this in

Re: [Haskell-cafe] gd on Win32

2010-07-22 Thread Dougal Stanton
On Fri, Jul 2, 2010 at 8:34 PM, Christopher Done chrisd...@googlemail.com wrote: That sounds like a good idea. I've setup a repo, I've merged in the latest work I did on it, and I've just updated it to be latest Prelude/base and to comply with -Wall. I'm just going to make it consistent with

Re: [Haskell-cafe] bounded ranges

2010-07-22 Thread Henning Thielemann
On Thu, 22 Jul 2010, Chad Scherrer wrote: Hello cafe, I'm trying to do some things with bounded indices so I can carry around arrays (well, Vectors, really) without needing to refer to the bounds. For example, if I know my indices are Bool values, I can do rangeSize (minBound, maxBound ::

Re: [Haskell-cafe] bounded ranges

2010-07-22 Thread Daniel Fischer
On Friday 23 July 2010 00:21:49, Chad Scherrer wrote: Hello cafe, I'm trying to do some things with bounded indices so I can carry around arrays (well, Vectors, really) without needing to refer to the bounds. For example, if I know my indices are Bool values, I can do rangeSize

[Haskell-cafe] Re: bounded ranges

2010-07-22 Thread Chad Scherrer
On Thu, 22 Jul 2010, Chad Scherrer wrote: I thought it might help to put it into a module and do a better job with the type, like this: bdRangeSize :: (Ix i, Bounded i) = i - Int bdRangeSize _ = rangeSize (minBound, maxBound :: i) Henning Thielemann lemming at henning-thielemann.de

Re: [Haskell-cafe] bounded ranges

2010-07-22 Thread Sebastian Fischer
On Jul 23, 2010, at 12:21 AM, Chad Scherrer wrote: bdRangeSize :: (Ix i, Bounded i) = i - Int bdRangeSize _ = rangeSize (minBound, maxBound :: i) Unlike intended, the `i` in the type annotation to `maxBound` is not the same as the `i` in the signature of `bdRangeSize`. You need to enable

Re: [Haskell-cafe] bounded ranges

2010-07-22 Thread Chad Scherrer
On Thu, Jul 22, 2010 at 3:43 PM, Daniel Fischer daniel.is.fisc...@web.de wrote: {-# LANGUAGE ScopedTypeVariables #-} bdRangeSize :: forall i. (Ix i, Bounded i) = i - Int Ah nice, I tried a forall in that position, but I didn't know about ScopedTypeVariables. Thanks! Chad

Re: [Haskell-cafe] bounded ranges

2010-07-22 Thread Sebastian Fischer
An alternative to the `asTypeOf` idiom, which is also Haskell 98, is to use a newtype instead of a dummy argument: newtype RangeSize i = RangeSize { getRangeSize :: Int } boundedRangeSize :: Ix i = (i,i) - RangeSize i boundedRangeSize = RangeSize . rangeSize bdRangeSize ::

[Haskell-cafe] ANNOUNCE: Haskell Platform 2010.2.0.0

2010-07-22 Thread Don Stewart
We're pleased to announce the fifth release of the Haskell Platform: a single, standard Haskell distribution for everyone. Download the Haskell Platform 2010.2.0.0: http://hackage.haskell.org.nyud.net/platform/ (Caching server). The specification, along with installers (including Windows,

Re: [Haskell-cafe] ANNOUNCE: Haskell Platform 2010.2.0.0

2010-07-22 Thread Felipe Lessa
On Thu, Jul 22, 2010 at 9:00 PM, Don Stewart d...@galois.com wrote: We're pleased to announce the fifth release of the Haskell Platform: a single, standard Haskell distribution for everyone. That's just great, dons! Thanks a lot! Cheers, =) -- Felipe.

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread wren ng thornton
Magnus Therning wrote: On Thu, Jul 22, 2010 at 11:52, Ross Paterson r...@soi.city.ac.uk wrote: On Thu, Jul 22, 2010 at 11:31:21AM +0100, Magnus Therning wrote: On Thu, Jul 22, 2010 at 10:59, Ross Paterson r...@soi.city.ac.uk wrote: Magnus is building by directly running the Setup.hs himself,

Re: [Haskell-cafe] Experiences with cabal-install and Hackage

2010-07-22 Thread Ivan Miljenovic
On 23 July 2010 02:31, Daniel Fischer daniel.is.fisc...@web.de wrote: On Thursday 22 July 2010 18:23:32, Stephen Tetley wrote: Hiding unmaintained libraries seems contrary to Hackage's spirit - if you want to depend on an unmaintained library why not volunteer to be the maintainer. I think

Re: [Haskell-cafe] On documentation

2010-07-22 Thread Ivan Miljenovic
On 22 July 2010 18:33, David Waern david.wa...@gmail.com wrote: [snip] We currently only support concrete examples (i.e. unit tests), but the plan is to add support for QuickCheck properties. Would you have some kind of inbuilt time limit (similar to what mueval has) for very long/complex QC

Re: [Haskell-cafe] cabal, Setup.lhs example

2010-07-22 Thread Mark Wotton
On Fri, Jul 23, 2010 at 12:33 PM, wren ng thornton w...@freegeek.org wrote: Magnus Therning wrote: On Thu, Jul 22, 2010 at 11:52, Ross Paterson r...@soi.city.ac.uk wrote: On Thu, Jul 22, 2010 at 11:31:21AM +0100, Magnus Therning wrote: On Thu, Jul 22, 2010 at 10:59, Ross Paterson