News aggregator

Are list comprehensions idiomatic in modern Haskell style?

Haskell on Reddit - Thu, 10/23/2014 - 4:15pm

I've been noticing dozens of recent Stack Overflow questions asking how to do things specifically with list comprehensions ("I want to write a function that uses list comprehensions...") ("I'm trying to use list comprehension to return the list elements that differ from the next.") or otherwise has a map or other operation shoehorned into a comprehension ("capitalise str = [ toUpper x | x <- str ]").

My assumption is that these are all telltales of homework assignments of the form "Using a list comprehension..." or just a teacher somewhere that's really partial to the sugar.

My sense is that list comprehensions in general are rarely idiomatic in "production" these days; rather, we prefer to use folds, map/fmap, scans, sometimes explicit recursion, or perhaps the monad with do. What's the community feeling on this topic?

submitted by conklech
[link] [51 comments]
Categories: Incoming News

acid-state problem.

haskell-cafe - Thu, 10/23/2014 - 9:06am
Hi, I have following code. In init, I called update, createCheckpoint, and close. So every time the code runs, if the DB did not exist, it would ask some configurations and create one. But actually it asks for init every time. How should I use it? state <- openLocalStateFrom dbFolder $ State ConfNone conf <- query state QueryState case conf of ConfNone -> init state m c -> process state m c
Categories: Offsite Discussion

Multiple Postdoc Positions on Formal Methods for CyberSecurity

General haskell list - Thu, 10/23/2014 - 7:30am
Title: Multiple Postdoc Positions on Formal Methods for Cyber Security Nanyang Technological University and Singapore University of Technology and Design Highly motivated applicants are sought to work on developing and applying verification techniques for infinite state systems in the project on Building Security Verified System. The project aims to fully verify the execution stack of a cyber-physical system: i.e., hardware, operating system, system libraries and applications, using model checking and theorem proving technologies. The postdocs will work with the PAT formal methods research group ( and other researchers at NTU and SUTD in Singapore. They will also have the opportunity to travel overseas to collaborate with partners of the project, including ETH Zurich, Oxford University, Royal Holloway University of London, University of Luxembourg, Hong Kong University of Science and Technology. Positions for Research Fellow and Senior Rese
Categories: Incoming News

Haskell Weekly News: Issue 310

haskell-cafe - Thu, 10/23/2014 - 4:36am
Welcome to issue 310 of the HWN, an issue covering crowd-sourced bits of information about Haskell from around the web. This issue covers from October 5 to 18, 2014 Quotes of the Week * spopejoy: That [Spineless Tagless G Machine] will always sound like the villian in an upcoming Ghostbusters sequel to me :) * pigworker: When you can make data out of potatoes, why would you want to encode them as functions? * fishcorn: When someone mentions lens on freenode... [1]zeus-lens! * neelk: So constructively we know this style can be used to meet hard performance deadlines in domains where the penalty for failure is literally radioactive flaming death. * edwardkmett: At one point we had a type in lens where one of its arguments started taking parameters of the form i m a s t a b u. Upon reflection, we let it win the argument and decided not to implement the function. * Ivan Appel: ... while the popular opinion says that the main reason to pick Haskell
Categories: Offsite Discussion

Test Framework, HUnit

haskell-cafe - Wed, 10/22/2014 - 8:48pm
Hi, I started using Test Framework following the example of the lens library, specifically using Test.Framework.TH. It looks really nice, however I noticed that the TH project hasn't had any activity in 2 years ... plus the whole test framework project is very light on docs. I've been happy with straight HUnit, but I'm wanting something more structured to bring others into the project I'm working on. 1) Are there more resources on TF? 2) Is TF-TH actively maintained? Cheers, Stuart
Categories: Offsite Discussion

Proposal: Let OpenGL depend on the StateVar package

libraries list - Wed, 10/22/2014 - 6:30pm
We're currently actively working on writing better SDL 2 bindings in sdl2. For various reasons, it can't depend on the OpenGL package directly, but it needs a state variable construction. Sadly, not every platform with SDL 2 has OpenGL -- thanks Microsoft. We'd like to depend on the StateVar package, but then we'll get two versions of the notion of a StateVar that conflict. By *far* the cleanest option for us moving forward would be if OpenGL switched to using the externalStateVar package that you also maintain, then we could incur a dependency on that. I realize that when this was last proposed there was some pushback from the Haskell Platform, but otherwise what we're going to start seeing is a profusion of almost-compatible APIs, which is the very thing that the Haskell Platform is meant to prevent. This would necessitate adding StateVar to the Haskell Platform, as OpenGL is in the Haskell Platform. The package is maintained by the same maintainer as the current OpenGL package. Discussion Perio
Categories: Offsite Discussion

[Announce] Lambdaheads - Vienna Functional Programming - 2014-10-12 Wed 19:00

Haskell on Reddit - Wed, 10/22/2014 - 12:22pm

Hey friends of the functional!

The Lambdaheads are meeting (again). Meetup


  • Web scraping in Haskell (Gregor)
  • Progress of the reporting tool, epsilonhalbe writes

If anybody wants to contribute, present or suggest any topics - you are welcome to do so!

Language spoken is either German or English, depending on the attendees.

Looking forward to meeting you Martin (epsilonhalbe)

submitted by epsilonhalbe
[link] [comment]
Categories: Incoming News

GHC 7.4.2 on Ubuntu Trusty

glasgow-user - Wed, 10/22/2014 - 11:48am
In order support some older software that we released, we need to get a working GHC 7.4.2 on Ubuntu Trusty. We currently have GHC 7.8.3. The binary tarball for GHC 7.4.2 does not install on Trusty due to multiple incompatibilities. For example, GHC requires GMP 3, but Trusty only provides GMP >= 4. Etc. I tried building GHC 7.4.2. from source on Trusty. But the process won't boot from our currently installed GHC 7.8.3. The oldest GHC binary I can get is GHC 7.6.3, which happens to be still available from the Ubuntu distribution itself (neither the binary tarball nor compiling from source work for GHC 7.6.3 on Trusty either). But booting from GHC 7.6.3 won't work either. How do I get a working GHC 7.4.2 on Trusty? Thanks, Yitz
Categories: Offsite Discussion

Timing execution of individual functions in ghci?

haskell-cafe - Wed, 10/22/2014 - 11:05am
When playing around with various implementations of a single function it would be nice to time the execution. Is there some way to do that easily from within GHCi? Or am I forced to look to criterion for that? /M
Categories: Offsite Discussion

Haskell Job

Haskell on Reddit - Wed, 10/22/2014 - 10:59am

PivotCloud (formerly AlephCloud) is an early stage Silicon Valley startup creating a secure content management system. Haskell is our main server side language and we are looking to hire a senior developer to help with design and implementation, as well as some team management. A qualified candidate should be comfortable with both high-level idioms (e.g. transformer stacks, applicatives, existential types, STM, etc.) and low-level performance considerations (e.g. when to be lazy or strict, INLINE pragmas, etc.); as well having some industrial programming experience such as shipping a product. Some topics of interest to us are: cloud services, cryptography/security, cross compilation (javascript, iOS, ARM). The position is in Sunnyvale, and we are willing to help with relocation.

If interested feel free to contact me ( for more information, or send a message (and/or a resume) to

thanks, Jeff

submitted by jeffpatalephcloud
[link] [29 comments]
Categories: Incoming News