Re: [Haskell-cafe] Compiling arbitrary Haskell code

2013-10-11 Thread Johan Tibell
Whatever guarantees GHC offers (e.g. using Safe Haskell), I would always run things like these in a sandbox. It's much better for security to dissallow everything and then whitelist some things (e.g. let the sandbox communicate with the rest of the world in some limited way) than the other way arou

Re: [Haskell-cafe] Telling Cassava to ignore lines

2013-09-17 Thread Johan Tibell
Hi, It depends on what you mean by "doesn't parse". From your message is assume the CSV is valid, but some of the actual values fails to convert (using FromField). There are a couple of things you could try: 1. Define a newtype for your field that calls runParser using e.g. the Int parser and if

Re: [Haskell-cafe] Cabal --enable-tests

2013-09-09 Thread Johan Tibell
I don't think so. Perhaps we should set one. What's your use case? Perhaps you could describe it in a new bug report at https://github.com/haskell/cabal/issues On Mon, Sep 9, 2013 at 7:29 PM, satvik chauhan wrote: > Hi cafe, > > > I wanted to ask this as I couldn't find this in cabal documentati

Re: [Haskell-cafe] ANN: Cabal v1.18.0 released

2013-09-05 Thread Johan Tibell
Hideyuki Tanaka was missing from the list of contributors (his patch was applied through me). His contribution made 'cabal update' faster! On Wed, Sep 4, 2013 at 2:11 PM, Johan Tibell wrote: > Hi all, > > On behalf of the cabal maintainers and contributors I'm proud

Re: [Haskell-cafe] ANN: Cabal v1.18.0 released

2013-09-05 Thread Johan Tibell
I pasted your report into the bug tracker: https://github.com/haskell/cabal/issues/1478 I don't know if you're on GitHub or not so I could link the report to your user. On Thu, Sep 5, 2013 at 8:16 AM, Rogan Creswick wrote: > I ran into another oddity due to old build artifacts today -- it was ea

[Haskell-cafe] ANN: Cabal v1.18.0 released

2013-09-04 Thread Johan Tibell
r look at the GitHub compare page: https://github.com/haskell/cabal/compare/cabal-install-v1.16.0.2...cabal-install-v1.18.0 (only shows the last 250 commits). 57 people contributed to this release! 503 Mikhail Glushenkov 99 Johan Tibell 41 Duncan Coutts 39 Ian Lynagh

Re: [Haskell-cafe] Debugging ByteString and Data.Binary.Get memory usage

2013-08-29 Thread Johan Tibell
A good starting point is to estimate how much space you think the data should take using e.g. http://blog.johantibell.com/2011/06/memory-footprints-of-some-common-data.html If you do that, is the actual space usage close to what you expected? On Thu, Aug 29, 2013 at 5:35 PM, Kyle Hanson wrote

Re: [Haskell-cafe] Building recent Cabal/cabal-install

2013-08-29 Thread Johan Tibell
Hi, Cabal 1.18 is still in the release candidate stage so it has in fact not been released yet. We could either bump the dependency on base to <4.8 before the 1.8 release or we could make a Cabal-1.8.0.1 release together with the GHC release that bumps the dependency. -- Johan On Wed, Aug 28, 2

Re: [Haskell-cafe] Ideas on a fast and tidy CSV library

2013-08-21 Thread Johan Tibell
d, thus running in constant memory. My > programme instead quickly approaches full memory use. Is there any way to > work around this? > > Justin > > > On 25 July 2013 17:53, Johan Tibell wrote: >> >> You can use the Incremental or Streaming modules to get more fine

Re: [Haskell-cafe] Ideas on a fast and tidy CSV library

2013-07-25 Thread Johan Tibell
> > > On 23 July 2013 22:13, Johan Tibell wrote: >> >> On Tue, Jul 23, 2013 at 5:45 PM, Ben Gamari >> wrote: >> > Justin Paston-Cooper writes: >> > >> >> Dear All, >> >> >> >> Recently I have been doing a lot of CSV

Re: [Haskell-cafe] Ideas on a fast and tidy CSV library

2013-07-23 Thread Johan Tibell
On Tue, Jul 23, 2013 at 5:45 PM, Ben Gamari wrote: > Justin Paston-Cooper writes: > >> Dear All, >> >> Recently I have been doing a lot of CSV processing. I initially tried to >> use the Data.Csv (cassava) library provided on Hackage, but I found this to >> still be too slow for my needs. In the

Re: [Haskell-cafe] Not working examples in GHC API documentation

2013-07-18 Thread Johan Tibell
I filed a bug a while back: http://ghc.haskell.org/trac/ghc/ticket/7752 Someone that understands the API needs to fix the doc. :) On Thu, Jul 18, 2013 at 7:58 PM, John Blackbox wrote: > Hi! > Please take a look here: http://www.haskell.org/haskellwiki/GHC/As_a_library > The examples are not

Re: [Haskell-cafe] GSoC - A Cabal Project

2013-04-30 Thread Johan Tibell
Sounds like a good idea. Go ahead and apply. :) On Tue, Apr 30, 2013 at 2:46 AM, Martin Ruderer wrote: > Hi, > > I am proposing a GSoC project on Cabal. It aims to open up the dependency > solver > for debugging purposes. > > The details are here: https://gist.github.com/mr-/7995081f89cff38e9443

Re: [Haskell-cafe] Diving into the records swamp (possible GSoC project)

2013-04-26 Thread Johan Tibell
Hi Adam, Since we have already had *very* long discussions on this topic, I'm worried that I might open a can of worms be weighing in here, but the issue is important enough to me that I will do so regardless. Instead of endorsing one of the listed proposals directly, I will emphasize the problem

Re: [Haskell-cafe] Stream fusion and span/break/group/init/tails

2013-04-25 Thread Johan Tibell
On Thu, Apr 25, 2013 at 9:20 PM, Ben Lippmeier wrote: > > On 26/04/2013, at 2:15 PM, Johan Tibell wrote: > >> Hi Ben, >> >> On Thu, Apr 25, 2013 at 7:46 PM, Ben Lippmeier wrote: >>> The Repa plugin will also do proper SIMD vectorisation for stream programs,

Re: [Haskell-cafe] Stream fusion and span/break/group/init/tails

2013-04-25 Thread Johan Tibell
On Thu, Apr 25, 2013 at 10:30 PM, Andrew Cowie wrote: > On Thu, 2013-04-25 at 21:15 -0700, Johan Tibell wrote: > >> {-# LANGUAGE Strict #-} > > God, I would love this. Obviously the plugin approach could do it, but > could not GHC itself just _not create thunks_ for thing

Re: [Haskell-cafe] Stream fusion and span/break/group/init/tails

2013-04-25 Thread Johan Tibell
Hi Ben, On Thu, Apr 25, 2013 at 7:46 PM, Ben Lippmeier wrote: > The Repa plugin will also do proper SIMD vectorisation for stream programs, > producing the SIMD primops that Geoff recently added. Along the way it will > brutally convert all operations on boxed/lifted numeric data to their unbox

Re: [Haskell-cafe] Fwd: GSoC Project Proposal: Markdown support for Haddock

2013-04-09 Thread Johan Tibell
On Tue, Apr 9, 2013 at 12:40 PM, Joe Nash wrote: > I would be interested in discussing this project with a potential mentor if > one happens to be reading. I'm a second year Computer Science student at the > University of Nottingham, very interested in doing a haskell.org SoC > project. Normally

Re: [Haskell-cafe] [haskell.org Summer of Code 2013] We're In!

2013-04-08 Thread Johan Tibell
Thanks for working on this again this year! On Mon, Apr 8, 2013 at 12:50 PM, Edward Kmett wrote: > We (haskell.org) have been officially accepted into the Google Summer of > Code for 2013. We should show up in the mentoring organization list as soon > as I get some information we need to finalize

Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock

2013-04-04 Thread Johan Tibell
> Would it be too much to ask that a notation be used which has > a formal syntax and a formal semantics? We will document our superset, sure. That's what others did as well. The point is using Markdown as the shared base. ___ Haskell-Cafe mailing list

Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock

2013-04-04 Thread Johan Tibell
On Thu, Apr 4, 2013 at 9:49 AM, Johan Tibell wrote: > I suggest that we implement an alternative haddock syntax that's a > superset of Markdown. It's a superset in the sense that we still want > to support linkifying Haskell identifiers, etc. Modules that want to > use the

[Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock

2013-04-04 Thread Johan Tibell
Hi all, Haddock's current markup language leaves something to be desired once you want to write more serious documentation (e.g. several paragraphs of introductory text at the top of the module doc). Several features are lacking (bold text, links that render as text instead of URLs, inline HTML).

Re: [Haskell-cafe] [Haskell] ANN: psqueue-benchmarks - benchmarks of priority queue implementations

2013-03-29 Thread Johan Tibell
I had a 5 second look at the PSQueue implementation and here's what I got so far: * fromList should use foldl'. * LTree should be spine strict (i.e. strict in the (LTree k p) fields). * Winner should be strict in the (LTree k p) field and probably in all other fields as well. This is a nice ex

Re: [Haskell-cafe] Associated types for number coercion

2013-03-19 Thread Johan Tibell
On Tue, Mar 19, 2013 at 3:58 PM, Christopher Done wrote: > From the paper Fun with Type Funs, it's said: > > > One compelling use of such type functions is to make type > > coercions implicit, especially in arithmetic. Suppose we want to be able > to > > write add a b to add two numeric values a a

[Haskell-cafe] Fwd: Now Accepting Applications for Mentoring Organizations for GSoC 2013

2013-03-18 Thread Johan Tibell
[bcc: hask...@haskell.org] We should make sure that we apply for Google Summer of Code this year as well. It's been very successful in the previous year, where we have gotten several projects funded every year. -- Johan -- Forwarded message -- From: Carol Smith Date: Mon, Mar 18

Re: [Haskell-cafe] GSOC application level

2013-03-06 Thread Johan Tibell
Hi Mateusz, On Wed, Mar 6, 2013 at 4:58 PM, Mateusz Kowalczyk wrote: > Can someone that has been around for a bit longer comment on what level > of experience with Haskell and underlying concepts is usually expected > from candidates? Are applications discarded simply based on the > applicant not

Re: [Haskell-cafe] Concurrency performance problem

2013-03-04 Thread Johan Tibell
On Mon, Mar 4, 2013 at 11:39 AM, Łukasz Dąbek wrote: > Thank you for your help! This solved my performance problem :) > > Anyway, the second question remains. Why performance of single > threaded calculation is affected by RTS -N parameter. Is GHC doing > some parallelization behind the scenes? >

Re: [Haskell-cafe] The state of binary (de)serialization

2013-02-27 Thread Johan Tibell
On Tue, Feb 26, 2013 at 11:17 PM, Vincent Hanquez wrote: > On Mon, Feb 25, 2013 at 11:59:42AM -0800, Johan Tibell wrote: > > > - cereal can output a strict bytestring (runPut) or a lazy one > > > (runPutLazy), whilst binary only outputs lazy ones (runPut) > > >

Re: [Haskell-cafe] The state of binary (de)serialization

2013-02-25 Thread Johan Tibell
On Mon, Feb 25, 2013 at 4:51 PM, Alexander Solla wrote: > On Mon, Feb 25, 2013 at 11:59 AM, Johan Tibell wrote: > >> >> There are some blog posts and comments out there about merging cereal >>> and binary, is this what's the goal/going on (cfr runGetIncremental)

Re: [Haskell-cafe] ANN: lazy-csv - the fastest and most space-efficient parser for CSV

2013-02-25 Thread Johan Tibell
On Mon, Feb 25, 2013 at 2:32 PM, Don Stewart wrote: > Cassava is quite new, but has the same goals as lazy-csv. > > Its about a year old now - > http://blog.johantibell.com/2012/08/a-new-fast-and-easy-to-use-csv-library.html > > I know Johan has been working on the benchmarks of late - it would b

Re: [Haskell-cafe] The state of binary (de)serialization

2013-02-25 Thread Johan Tibell
On Mon, Feb 25, 2013 at 4:30 AM, Nicolas Trangez wrote: > - cereal supports chunk-based 'partial' parsing (runGetPartial). It > looks like support for this is introduced in recent versions of 'binary' > as well (runGetIncremental) > Yes. Binary now support an incremental interface. We intend to m

Re: [Haskell-cafe] What magic has the new IO manager done to improve performance ?

2013-02-16 Thread Johan Tibell
Hi, On Saturday, February 16, 2013, yi huang wrote: > I' m curious about the design and trade offs behind the new IO manager. I > see two changes from the code: > > 1. Run IO manager thread on each capability. > 2. Use ONESHOT flag to save a system call. > > Is there other interesting things to k

[Haskell-cafe] Fwd: Google Summer of Code 2013

2013-02-11 Thread Johan Tibell
Hi all, Summer of code has always been a good way for us to get some important work, that no one has time to do, done. I encourage everyone to come up with good summer of code projects so we have a good number when the time for students to apply comes around. Empirically projects that focus on exi

Re: [Haskell-cafe] cabal-dev add-source

2013-02-08 Thread Johan Tibell
On Fri, Feb 8, 2013 at 10:24 AM, Ozgun Ataman wrote: > Which, thanks to Johan's help yesterday, can still be worked around (for > now) by starting ghci with: > > ghci -package-conf ./cabal-sandbox/your-package-conf-folder-here/ > You can indeed do this. For real ghci support in cabal we need to

Re: [Haskell-cafe] cabal-dev add-source

2013-02-08 Thread Johan Tibell
On Fri, Feb 8, 2013 at 10:07 AM, JP Moresmau wrote: > Johan, thanks, that brings me to a point that I wanted to raise. I'm > playing with cabal-dev because users have asked me to add support for it in > EclipseFP (so projects could have their own sandbox and have dependencies > between projects w

Re: [Haskell-cafe] cabal-dev add-source

2013-02-08 Thread Johan Tibell
On Fri, Feb 8, 2013 at 9:53 AM, Blake Rain wrote: > You need to call cabal-dev add-source on P1 again to copy over the sdist, > then do a cabal-dev install. > > See notes under "Using a sandbox-local Hackage" on > https://github.com/creswick/cabal-de > With

Re: [Haskell-cafe] Substantial (1:10??) system dependencies of runtime performance??

2013-02-02 Thread Johan Tibell
On Sat, Feb 2, 2013 at 5:14 PM, Ozgun Ataman wrote: > If you are doing row-by-row transformations, I would recommend giving a try > to my csv-conduit or csv-enumerator packages on Hackage. They were designed > with constant space operation in mind, which may help you here. > > If you're keeping

Re: [Haskell-cafe] Handling exceptions or gracefully releasing resources

2013-01-29 Thread Johan Tibell
Hi, The pattern is essentially the same as in imperative languages; every allocation should involve a finally clause that deallocates the resource. On Tue, Jan 29, 2013 at 2:59 PM, Thiago Negri wrote: > Should I put `Control.Exception.finally` on every single line of my > finalizers? I'm not su

Re: [Haskell-cafe] Heads up: planned removal of String instances from HTTP package

2013-01-29 Thread Johan Tibell
On Tue, Jan 29, 2013 at 2:15 PM, Ganesh Sittampalam wrote: > tl;dr: I'm planning on removing the String instances from the HTTP > package. This is likely to break code. Obviously it will involve a major > version bump. > > The basic reason is that this instance is rather broken in itself. A > Stri

Re: [Haskell-cafe] Mac os x (Intel, 10.6.8) problem compiling yesod-core-1.1.7.1

2013-01-28 Thread Johan Tibell
Adding Bryan, who wrote this code. On Mon, Jan 28, 2013 at 1:23 AM, jean-christophe mincke wrote: > Hello > > GHC version : 7.4.2 > > When I do a cabal-dev instal yesod-core, I get the following error: > > Loading package blaze-builder-conduit-0.5.0.3 ... linking ... done. > Loading package hasha

Re: [Haskell-cafe] Space leaks in function that uses Data.Vector.Mutable

2013-01-23 Thread Johan Tibell
Hi! You have to look outside the place function, which is strict enough. I would look for a call to unsafeWrite that doesn't evaluate it's argument before writing it into the vector. Perhaps you're doing something like: MV.unsafeWrite (i + 1, ...) Since tuples are lazy the i + 1 will be stor

Re: [Haskell-cafe] Example programs with ample use of deepseq?

2013-01-07 Thread Johan Tibell
On Mon, Jan 7, 2013 at 4:06 AM, Joachim Breitner wrote: > I’m wondering if the use of deepseq to avoid unwanted lazyness might be > a too large hammer in some use cases. Therefore, I’m looking for real > world programs with ample use of deepseq, and ideally easy ways to test > performance (so pref

Re: [Haskell-cafe] containers license issue

2012-12-12 Thread Johan Tibell
On Wed, Dec 12, 2012 at 5:38 PM, Michael Orlitzky wrote: > On 12/12/2012 08:15 PM, Johan Tibell wrote: >> On Wed, Dec 12, 2012 at 12:18 PM, Dmitry Kulagin >> wrote: >>> Clark, Johan, thank you! That looks like perfect solution to the problem. >> >> Clean-room

Re: [Haskell-cafe] containers license issue

2012-12-12 Thread Johan Tibell
On Wed, Dec 12, 2012 at 12:18 PM, Dmitry Kulagin wrote: > Clark, Johan, thank you! That looks like perfect solution to the problem. Clean-room reimplementation merged and released as 0.5.2.0. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http:

Re: [Haskell-cafe] containers license issue

2012-12-12 Thread Johan Tibell
On Wed, Dec 12, 2012 at 12:09 PM, Clark Gaebel wrote: > Possibly. I tend to trust GHC's strictness analyzer until proven otherwise, > though. Feel free to optimize as necessary. The GHC strictness analyzer will have no troubles with this. Since the return type is Word64, there's no place for thun

Re: [Haskell-cafe] containers license issue

2012-12-12 Thread Johan Tibell
On Wed, Dec 12, 2012 at 10:40 AM, Clark Gaebel wrote: > I just did a quick derivation from > http://graphics.stanford.edu/~seander/bithacks.html#RoundUpPowerOf2 to get > the highest bit mask, and did not reference FXT nor the containers > implementation. Here is my code: > > highestBitMask :: Word

Re: [Haskell-cafe] How is default method signatures supposed to be used together with Generics

2012-12-12 Thread Johan Tibell
On Tue, Dec 11, 2012 at 9:31 PM, dag.odenh...@gmail.com wrote: > The practice seems to be to not export it, but maybe it would be a better > practice to export it. That way it can work without DefaultSignatures too, > and if you use the generic-deriving package it could work with zero > extensions

[Haskell-cafe] How is default method signatures supposed to be used together with Generics

2012-12-11 Thread Johan Tibell
Hi, I noticed that you're not required to export the types mentioned in the default method signature. For example, you could have: default hashWithSalt :: (Generic a, GHashable (Rep a)) => Int -> a -> Int hashWithSalt salt = ghashWithSalt salt . from and not export the GHashable class. H

Re: [Haskell-cafe] The end of an era, and the dawn of a new one

2012-12-05 Thread Johan Tibell
On Wed, Dec 5, 2012 at 12:37 PM, David Terei wrote: > I have always considered the LLVM code generator my responsibility and > will continue to do so. I don't seem to find the time to make > improvements to it but make sure to keep it bug free and working with > the latest LLVM releases. So if oth

Re: [Haskell-cafe] Is it possible to have constant-space JSON decoding?

2012-12-04 Thread Johan Tibell
Hi Oleg, On Tue, Dec 4, 2012 at 9:13 PM, wrote: > I am doing, for several months, constant-space processing of large XML > files using iteratees. The file contains many XML elements (which are > a bit complex than a number). An element can be processed > independently. After the parser finished

Re: [Haskell-cafe] RFC: Changes to Travis CI's Haskell support

2012-12-03 Thread Johan Tibell
On Mon, Dec 3, 2012 at 1:04 AM, Simon Hengel wrote: > I think the right thing to do is: > > install: > - cabal install --only-dependencies --enable-tests > > script: > - cabal configure --enable-tests && cabal build && cabal test > > Please let me know if you think there are be

Re: [Haskell-cafe] Vedr: To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 2:02 PM, Johan Tibell wrote: > On Thu, Nov 29, 2012 at 2:01 PM, Daniel Fischer > wrote: >> On Donnerstag, 29. November 2012, 13:40:42, Johan Tibell wrote: >>> word2Double :: Word -> Double >>> word2Double (W# w) = D# (int2Double# (wo

Re: [Haskell-cafe] Vedr: To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 2:01 PM, Daniel Fischer wrote: > On Donnerstag, 29. November 2012, 13:40:42, Johan Tibell wrote: >> word2Double :: Word -> Double >> word2Double (W# w) = D# (int2Double# (word2Int# w)) >> >> On my (64-bit) machine the Haskell and C version

Re: [Haskell-cafe] Vedr: To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 1:40 PM, Johan Tibell wrote: > This version works around the Word->Double conversion bug and shows > good performance: I'd also like to point out that I've removed lots of bang patterns that weren't needed. This program runs fine without any bang

Re: [Haskell-cafe] Vedr: To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 1:32 PM, Daniel Fischer wrote: > We have an unpleasant regression in comparison to 7.2.* and the 7.4.* were > slower than 7.6.1 is, but it's all okay here (not that it wouldn't be nice to > have it faster still). > > Are you on a 32-bit system? This version works around th

Re: [Haskell-cafe] To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 1:23 PM, Fixie Fixie wrote: > That's really an argument for upgrading to 7.4.2 :-) > > Another reason for doing things with haskell is this mailing list. FYI I'm still looking into this issue as I'm not 100% happy with the code GHC generates. _

Re: [Haskell-cafe] To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
On Thu, Nov 29, 2012 at 1:00 PM, Fixie Fixie wrote: > The program seems to take around 6 seconds on my linux-box, while the c > version goes for 0.06 sekcond. > > That is really some regression bug :-) > > Anyone with a more recent version thatn 7.4.1? On 7.4.2: $ time ./c_test ... real0m0.

Re: [Haskell-cafe] To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
Ack, it seems like you're running into one of these bugs (all now fixed, but I don't know in which GHC version): http://hackage.haskell.org/trac/ghc/search?q=doubleFromInteger ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org

Re: [Haskell-cafe] To my boss: The code is cool, but it is about 100 times slower than the old one...

2012-11-29 Thread Johan Tibell
Hi Felix, On Thu, Nov 29, 2012 at 10:09 AM, Fixie Fixie wrote: > The problem seems to be connected to lazy loading, which makes my programs > so slow that I really can not show them to anyone. I have tried all tricks > in the books, like !, seq, non-lazy datatypes... My advice usually goes like

Re: [Haskell-cafe] Can a GC delay TCP connection formation?

2012-11-27 Thread Johan Tibell
Kazu and Andreas, could this be IO manager related? On Monday, November 26, 2012, Jeff Shaw wrote: > Hello, > I've run into an issue that makes me think that when the GHC GC runs while > a Snap or Warp HTTP server is serving connections, the GC prevents or > delays TCP connections from forming. M

Re: [Haskell-cafe] Common function names for '(.) . (.)', '(.) . (.) . (.)' ...?

2012-11-21 Thread Johan Tibell
On Wed, Nov 21, 2012 at 9:48 AM, MigMit wrote: > Tits? This is not appropriate for this mailing lists, please take it elsewhere. I suggest http://www.reddit.com/r/ruby ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailma

Re: [Haskell-cafe] Cabal failures...

2012-11-20 Thread Johan Tibell
On Tue, Nov 20, 2012 at 5:34 PM, Albert Y. C. Lai wrote: > This counter-argument is flawed. Why limit oneself to one's own household? > (Garage? Basement?) Get out more! Visit a friend. Talk to an internet cafe > owner for a special deal to run one's own programs. Rent virtual machine > time in t

Re: [Haskell-cafe] Cabal failures...

2012-11-20 Thread Johan Tibell
On Tue, Nov 20, 2012 at 5:14 PM, Albert Y. C. Lai wrote: > On 12-11-20 05:37 PM, Gregory Guthrie wrote: > >> No; the first sentence says that someone else had reported that testing >> on Windows was hard to do because of (a perceived) lack of access to >> Windows by Haskell developers... The impl

Re: [Haskell-cafe] cabal install...

2012-11-20 Thread Johan Tibell
On Tue, Nov 20, 2012 at 1:10 PM, Gregory Guthrie wrote: > Hmm, > > Now when I tried to run Leksah, I get not only some broken packages (which > I can avoid for my current project), but: > > ** ** > > : cannot satisfy -package-id > base-4.5.1.0-7c83b96f47f23db63c42a56351dcb917: > >

Re: [Haskell-cafe] Cabal failures...

2012-11-19 Thread Johan Tibell
On Mon, Nov 19, 2012 at 2:55 PM, Greg Fitzgerald wrote: > > cabal install -v cabal-install > > Not sure if you're running into this one, but a configuration that > wasn't working for me: > > 1) Install Haskell Platform > 2) Install GHC 7.6.1 > 3) cabal install cabal-install > > As I recall, the e

Re: [Haskell-cafe] Cabal failures...

2012-11-19 Thread Johan Tibell
Hi Greg, On Mon, Nov 19, 2012 at 1:25 PM, Gregory Guthrie wrote: > I follow the Cabal-messes threads with some interest, since that is the > hardest area for me since starting to use Haskell. Probably 40-60% of all > package install fail for some mysterious reason, with threats that trying > to

Re: [Haskell-cafe] Automation of external library installation in haskell package.

2012-11-18 Thread Johan Tibell
Hi, On Sun, Nov 18, 2012 at 11:51 AM, Maksymilian Owsianny < maksymilian.owsia...@gmail.com> wrote: > However, the problem with hackage not being able to build the package, and > therefore generate documentation, remains. So conversely my question would > be > if there is any way to get around th

Re: [Haskell-cafe] How to determine correct dependency versions for a library?

2012-11-14 Thread Johan Tibell
On Wed, Nov 14, 2012 at 1:01 PM, Tobias Müller wrote: > Clark Gaebel wrote: > > To prevent this, I think the PVP should specify that if dependencies get > > a major version bump, the package itself should bump its major version > > (preferably the B field). > > No, it has nothing to do with majo

Re: [Haskell-cafe] How to determine correct dependency versions for a library?

2012-11-12 Thread Johan Tibell
On Mon, Nov 12, 2012 at 1:06 AM, Erik Hesselink wrote: > tl;dr: Breakages without upper bounds are annoying and hard to solve for > package consumers. With upper bounds, and especially with sandboxes, > breakage is almost non-existent. > > I don't see how things break with upper bounds, at least

Re: [Haskell-cafe] Motion to unify all the string data types

2012-11-10 Thread Johan Tibell
On Fri, Nov 9, 2012 at 10:22 PM, Roman Cheplyaka wrote: > * Johan Tibell [2012-11-09 19:00:04-0800] > > As a community we should primary use strict ByteStrings and Texts. There > > are uses for the lazy variants (i.e. they are sometimes more efficient), > > but in genera

Re: [Haskell-cafe] Taking over ghc-core

2012-11-10 Thread Johan Tibell
On Saturday, November 10, 2012, Shachaf Ben-Kiki wrote: > With Don Stewart's blessing > (), I'll be > taking over maintainership of ghc-core, which hasn't been updated > since 2010. I'll release a version with support for GHC 7.6 later > today

Re: [Haskell-cafe] Motion to unify all the string data types

2012-11-09 Thread Johan Tibell
Hi Andrew, On Fri, Nov 9, 2012 at 6:15 PM, Andrew Pennebaker < andrew.penneba...@gmail.com> wrote: > Frequently when I'm coding in Haskell, the crux of my problem is > converting between all the stupid string formats. > > You've got String, ByteString, Lazy ByteString, Text, [Word], and on and >

Re: [Haskell-cafe] Does anyone know where George Pollard is?

2012-11-07 Thread Johan Tibell
On Wed, Nov 7, 2012 at 9:03 PM, Myles C. Maxfield wrote: > Does anyone know where he is? If not, is there an accepted practice to > resolve this situation? Should I upload my own 'idna2' package. > Generally we try to contact the maintainer (and give him/her enough time to reply, in case he/she i

Re: [Haskell-cafe] Defining a Strict language pragma

2012-11-05 Thread Johan Tibell
On Mon, Nov 5, 2012 at 3:28 PM, Iustin Pop wrote: > Did you mean here "it's still possible to define _lazy_ arguments"? The > duality of !/~ makes sense, indeed. Yes, it would be nice to still make arguments explicitly lazy, using "~". ___ Haskell-Caf

[Haskell-cafe] Defining a Strict language pragma

2012-11-05 Thread Johan Tibell
Hi all, I would like to experiment with writing some modules (e.g. low-level modules that do a lot of bit twiddling) in a strict subset of Haskell. The idea is to remove boilerplate bangs (!) and instead declare the whole module strict. I believe this would both make code that needs to be strict m

Re: [Haskell-cafe] [ANNOUNCE] hashable-generics

2012-11-04 Thread Johan Tibell
On Sun, Nov 4, 2012 at 8:35 AM, Clark Gaebel wrote: > > @dag: > > I would love for this to be merged into Data.Hashable, and I think it would > make a lot of people's lives easier, and prevent them from writing bad hash > functions accidentally. Couldn't we do it using GHC's default implementa

[Haskell-cafe] ANN: Cabal-1.16.0.2 and cabal-install-1.16.0.1

2012-10-24 Thread Johan Tibell
Hi, On behalf of the cabal contributors, I'm proud to announce bugfix releases of Cabal and cabal-install. Here's a complete list of changes since the last release: Since Cabal-1.16.0.1: * Bump Cabal version number to 1.16.0.2 * Fixed warnings on the generated Paths module. The warnings are gene

Re: [Haskell-cafe] cabal-install-1.16.0.2

2012-10-15 Thread Johan Tibell
On Mon, Oct 15, 2012 at 7:16 PM, Johan Tibell wrote: > Hi all, > > I've created bug fix release candidates for Cabal and cabal-install to > address the bugs found after the release. Here's the list of fixed bugs: Fixed since cabal-install-1.16.0: * Fix installing from

[Haskell-cafe] cabal-install-1.16.0.2

2012-10-15 Thread Johan Tibell
Hi all, I've created bug fix release candidates for Cabal and cabal-install to address the bugs found after the release. If everyone could take some time to try them out, especially those who had issues with the previous releases. To install the release candidates run: cabal install http://jo

Re: [Haskell-cafe] problem with cabal-install-1.16.0 and Cabal-1.16.0.1 on Haskell Platform for OS X

2012-10-09 Thread Johan Tibell
Hi, Thanks for the detailed problem description. I've CCed Mark Lentczner, who designed the directory layout for the Haskell Platform on OS X. Hopefully he'll be able to tell you what to do. On Tue, Oct 9, 2012 at 8:31 AM, Derrell Piper wrote: > Hi, > > New Haskell user here. I have the latest

Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-08 Thread Johan Tibell
Hi, I'll make a bugfix release for cabal-install and Cabal in a few days to include fixes to issues people found so far. If everyone who had some problem related to the latest release could please post it here so I can make sure that we include a fix for them. If you've already reported it elsewhe

Re: [Haskell-cafe] 64-bit vs 32-bit haskell platform on Mac: misleading notice on Platform website?

2012-10-08 Thread Johan Tibell
On Mon, Oct 8, 2012 at 3:28 AM, Christiaan Baaij wrote: > Hi, > > I finally found another OS X mountain lion install and can confirm the > behaviour I described earlier: > 32-bit: compiled code works, interpreted code works > 64-bit: compiled code works, interpreted code fails > > Here's the test

Re: [Haskell-cafe] Panic loading network on windows (GHC 7.6.1)

2012-10-05 Thread Johan Tibell
On Fri, Oct 5, 2012 at 5:31 PM, JP Moresmau wrote: > Hello, I've installed Cabal and cabal-install 1.16 (which required > network) on a new GHC 7.6.1 install and everything went well, except > now when building a package requiring network I get: > > Loading package network-2.4.0.1 ... ghc.exe: Unk

Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-04 Thread Johan Tibell
On Thu, Oct 4, 2012 at 7:11 PM, Tim Docker wrote: > > Does this new release included the sandbox functions discussed in this blog > post: > > http://blog.johantibell.com/2012/08/you-can-soon-play-in-cabal-sandbox.html > ? It doesn't. The sandbox feature requires a little UI work still. I expect t

Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-03 Thread Johan Tibell
On Wed, Oct 3, 2012 at 5:42 PM, Ivan Lazar Miljenovic wrote: > > On Oct 4, 2012 2:08 AM, "Johan Tibell" wrote: >> >> On the behalf of the many contributors to cabal, I'm proud to present >> cabal-install-1.16.0. > > Why the sudden change in versio

Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-03 Thread Johan Tibell
On Wed, Oct 3, 2012 at 9:15 PM, Austin Seipp wrote: > Just a heads up: on Ubuntu 12.04 with GHC 7.4.1 out of apt (no > haskell-platform,) using the bootstrap.sh script fails, because the > constraints for CABAL_VER_REGEXP are too lax: > > $ sh ./bootstrap.sh > Checking installed packages for ghc-7

Re: [Haskell-cafe] total Data.Map.! function

2012-10-03 Thread Johan Tibell
Hi, On Wed, Oct 3, 2012 at 7:52 PM, Henning Thielemann wrote: > I wondered whether there is a brilliant typing technique that makes > Data.Map.! a total function. That is, is it possible to give (!) a type, > such that m!k expects a proof that the key k is actually present in the > dictionary m?

Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-03 Thread Johan Tibell
On Wed, Oct 3, 2012 at 6:21 PM, José Lopes wrote: > Hello, > > I just tried to upgrade cabal-install using an older version and it yields > the following error: > Distribution/Client/JobControl.hs:63:6: Not in scope: `mask' We tested on GHC 7.0.4, 7.4.1, and 7.6.1. > If you need any machine/soft

[Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)

2012-10-03 Thread Johan Tibell
On the behalf of the many contributors to cabal, I'm proud to present cabal-install-1.16.0. This release contains almost a year worth of patches. Highlights include: * Parallel installs (cabal install -j) * Several improvements to the dependency solver. * Lots of bugfixes We're also simultaneo

Re: [Haskell-cafe] 64-bit vs 32-bit haskell platform on Mac: misleading notice on Platform website?

2012-09-26 Thread Johan Tibell
Adding Mark who's the release manager for the platform (and also the maintainer of the OS X builds). On Wed, Sep 26, 2012 at 11:57 AM, Erik Hesselink wrote: > On Wed, Sep 26, 2012 at 10:58 AM, Johan Tibell wrote: >> On Wed, Sep 26, 2012 at 7:44 AM, Carter Schonwald >> wrote

Re: [Haskell-cafe] 64-bit vs 32-bit haskell platform on Mac: misleading notice on Platform website?

2012-09-26 Thread Johan Tibell
Hi, On Wed, Sep 26, 2012 at 7:44 AM, Carter Schonwald wrote: > To the best of my knowledge there is absolutely no reason to use the 32bit > haskell on OS X (aside from memory usage optimization cases which likely do > not matter to the *typical* user), and the community should probably update > t

Re: [Haskell-cafe] How to implement nested loops with tail recursion?

2012-09-19 Thread Johan Tibell
On Wed, Sep 19, 2012 at 8:00 PM, wrote: > So how do I force IO actions whose results are discarded (including IO ()) to > be strict? In your particular case it looks like you want Data.IORef.modifyIORef'. If your version of GHC doesn't include it you can write it like so: -- |Strict version of

Re: [Haskell-cafe] How to implement nested loops with tail recursion?

2012-09-19 Thread Johan Tibell
On Wed, Sep 19, 2012 at 7:24 PM, wrote: > main = do > let > f 0 acc = return acc > f n acc = do > v <- return 1 > f (n-1) (v+acc) > f 100 100 >>= print Try this main = do let f :

Re: [Haskell-cafe] Destructive updates to plain ADTs

2012-09-09 Thread Johan Tibell
On Sun, Sep 9, 2012 at 2:19 AM, MigMit wrote: > Why modify it instead of creating the new one and let the previous tree get > garbage collected? You can avoid a bunch of copying and allocation by modifying the nodes in-place. See http://blog.johantibell.com/2012/03/improvements-to-hashmap-and-h

Re: [Haskell-cafe] Destructive updates to plain ADTs

2012-09-09 Thread Johan Tibell
On Sun, Sep 9, 2012 at 1:46 AM, Milan Straka wrote: > Hi all, > > is there any way to perform a destructive update on a plain ADT? > Imagine I have a simple > data Tree a = Nil | Node a (Tree a) (Tree a) > I would like to be able to modify right subtree of an existing tree. > > I can do that for

Re: [Haskell-cafe] performance issues with popCount

2012-09-07 Thread Johan Tibell
On Fri, Sep 7, 2012 at 4:54 AM, Nicolas Trangez wrote: > On Thu, 2012-09-06 at 12:07 -0700, Johan Tibell wrote: >> Have a look at the popCount implementation for e.g. Int, which are >> written in C and called through the FFI: >> >> https://github.com/ghc/packages

Re: [Haskell-cafe] performance issues with popCount

2012-09-06 Thread Johan Tibell
Hi Harald, On Thu, Sep 6, 2012 at 9:46 AM, Harald Bögeholz wrote: > Anyway, I tried this version > > popCount :: Integer -> Int > popCount = go 0 > where > go c 0 = c > go c w = go (c+1) (w .&. (w - 1)) > > and profiling showed that my program spent 80 % of its time counting b

Re: [Haskell-cafe] ANNOUNCE: persistent-vector-0.1.0.1

2012-08-29 Thread Johan Tibell
On Wed, Aug 29, 2012 at 10:13 AM, Alberto G. Corona wrote: > Where the "persistent" part of the name comes from?. It can be > serialized/deserialized from a persistent storage automatically or on > demand? Persistent have two meanings unfortunately. In functional programming it's used to mean tha

Re: [Haskell-cafe] Cabal Test-suites + custom preprocessors

2012-08-26 Thread Johan Tibell
On Sun, Aug 26, 2012 at 1:03 PM, Iain Nicol wrote: > Johan Tibell wrote: >> On Sun, Aug 26, 2012 at 12:40 PM, Iain Nicol wrote: >>> Does anybody know if Cabal actually supports using custom >>> preprocessors for building a test-suite? If so, is 'buildHook'

Re: [Haskell-cafe] Cabal Test-suites + custom preprocessors

2012-08-26 Thread Johan Tibell
On Sun, Aug 26, 2012 at 12:40 PM, Iain Nicol wrote: > Hi café, > > I am successfully using a custom preprocessor to build my main > executable. In particular, I am using UUAGC to preprocess .ag files > into .hs files. My Setup.hs file uses 'uuagcLibUserHook' from the > package uuagc-cabal to do

  1   2   3   4   5   6   >