[Haskell-cafe] Haskell meetups near Lund, Sweden?
Hi, Are there any Haskell or FP meetups near Lund, Sweden? I will be living there from October. Cheers, -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Installling Leksah on ghc7.6.3 with haskell-platform 2013?
On 09/08/13 16:35, Hamish Mackenzie wrote: You will need Leksah 0.13 for GHC 7.6.3 and it is not in Hackage yet. It is almost ready though. If run git clone https://github.com/leksah/leksah.git cd leksah cabal install cabal-meta cabal-src cabal-meta install It would be interesting to know if it works for you. On an up to date Debian Wheezy system with ghc 7.6.3, haskell platform 2013, git 1.7.10.4: ✓ 11:51:58 carlo@x1 (master) ~/tmp/leksah $ cabal-meta install git fetch origin git checkout master Already on 'master' git submodule foreach git pull origin master You need to run this command from the toplevel of the working tree. cabal-meta: log of commands saved to: /home/carlo/tmp/leksah/.shelly/1.txt Exception: error running: git submodule foreach git pull origin master exit status: 1 stderr: You need to run this command from the toplevel of the working tree. So instead I tried the initial git clone with --recursive, but there are some fatal errors (references that are not in the tree?). ✓ 12:01:44 carlo@x1 ~/tmp $ git clone --recursive https://github.com/leksah/leksah.git Cloning into 'leksah'... WARNING: gnome-keyring:: couldn't connect to: /home/carlo/.cache/keyring-yZXClI/pkcs11: No such file or directory remote: Counting objects: 8930, done. remote: Compressing objects: 100% (2431/2431), done. remote: Total 8930 (delta 6145), reused 8824 (delta 6044) Receiving objects: 100% (8930/8930), 17.53 MiB | 538 KiB/s, done. Resolving deltas: 100% (6145/6145), done. Submodule 'vendor/CodeMirror' (g...@github.com:ghcjs/CodeMirror.git) registered for path 'vendor/CodeMirror' Submodule 'vendor/ghcjs-dom' (g...@github.com:ghcjs/ghcjs-dom.git) registered for path 'vendor/ghcjs-dom' Submodule 'vendor/haskellVCSGUI' (g...@github.com:leksah/haskellVCSGUI.git) registered for path 'vendor/haskellVCSGUI' Submodule 'vendor/haskellVCSWrapper' (g...@github.com:leksah/haskellVCSWrapper.git) registered for path 'vendor/haskellVCSWrapper' Submodule 'vendor/jsc' (g...@github.com:ghcjs/jsc.git) registered for path 'vendor/jsc' Submodule 'vendor/leksah-server' (g...@github.com:leksah/leksah-server.git) registered for path 'vendor/leksah-server' Submodule 'vendor/ltk' (g...@github.com:leksah/ltk.git) registered for path 'vendor/ltk' Submodule 'vendor/pretty-show' (g...@github.com:leksah/pretty-show.git) registered for path 'vendor/pretty-show' Submodule 'vendor/vado' (g...@github.com:hamishmack/vado.git) registered for path 'vendor/vado' Submodule 'vendor/webkit-javascriptcore' (g...@github.com:ghcjs/webkit-javascriptcore.git) registered for path 'vendor/webkit-javascriptcore' Submodule 'vendor/yi' (g...@github.com:leksah/yi.git) registered for path 'vendor/yi' Cloning into 'vendor/CodeMirror'... X11 forwarding request failed on channel 0 remote: Counting objects: 14210, done. remote: Compressing objects: 100% (6388/6388), done. remote: Total 14210 (delta 8658), reused 13125 (delta 7792) Receiving objects: 100% (14210/14210), 2.95 MiB | 543 KiB/s, done. Resolving deltas: 100% (8658/8658), done. Submodule path 'vendor/CodeMirror': checked out '107612c9e854c61ed3aa94bee29a136438085557' Cloning into 'vendor/ghcjs-dom'... X11 forwarding request failed on channel 0 remote: Counting objects: 813, done. remote: Compressing objects: 100% (483/483), done. remote: Total 813 (delta 578), reused 546 (delta 313) Receiving objects: 100% (813/813), 363.52 KiB | 173 KiB/s, done. Resolving deltas: 100% (578/578), done. Submodule path 'vendor/ghcjs-dom': checked out 'c347df82e86136851b9d132d1c71d18ecb3f9f2a' Cloning into 'vendor/haskellVCSGUI'... X11 forwarding request failed on channel 0 remote: Counting objects: 1239, done. remote: Compressing objects: 100% (533/533), done. remote: Total 1239 (delta 688), reused 1227 (delta 677) Receiving objects: 100% (1239/1239), 13.05 MiB | 537 KiB/s, done. Resolving deltas: 100% (688/688), done. Submodule path 'vendor/haskellVCSGUI': checked out '5aaf804587c9e8b34dd669390666cdbcba564e4c' Cloning into 'vendor/haskellVCSWrapper'... X11 forwarding request failed on channel 0 remote: Counting objects: 1019, done. remote: Compressing objects: 100% (432/432), done. remote: Total 1019 (delta 569), reused 1008 (delta 558) Receiving objects: 100% (1019/1019), 2.66 MiB | 525 KiB/s, done. Resolving deltas: 100% (569/569), done. Submodule path 'vendor/haskellVCSWrapper': checked out '00e0ed2f007a8ca68d1b8a4ebf66a86b572b9647' Cloning into 'vendor/jsc'... X11 forwarding request failed on channel 0 remote: Counting objects: 221, done. remote: Compressing objects: 100% (146/146), done. remote: Total 221 (delta 95), reused 149 (delta 27) Receiving objects: 100% (221/221), 48.26 KiB, done. Resolving deltas: 100% (95/95), done. Submodule path 'vendor/jsc': checked out '99047d74b7036a4bf9172af548b9c80498f7a3c9' Cloning into 'vendor/leksah-server'... X11 forwarding request failed on channel 0 remote: Counting objects: 950, done. remote: Compressing objects: 100% (437/437), done.
[Haskell-cafe] Installling Leksah on ghc7.6.3 with haskell-platform 2013?
Hi, I'm trying to install Leksah from hackage on my Debian testing laptop, which has ghc 7.6.3 and the Haskell Platform 2013. I fixed a bunch of errors about catch not being exported from the Prelude, but now I'm stuck on these two errors in leksah-server-0.8.0.5: [10 of 13] Compiling IDE.Utils.GHCUtils ( src/IDE/Utils/GHCUtils.hs, dist/build/IDE/Utils/GHCUtils.o ) src/IDE/Utils/GHCUtils.hs:94:40-62: Not in scope: data constructor `Opt_ReadUserPackageConf' src/IDE/Utils/GHCUtils.hs:161:44-50: Not in scope: data constructor `Opt_Cpp' Perhaps you meant one of these: `Opt_CSE' (imported from GHC), `Opt_Pp' (imported from GHC) Where have Opt_ReadUserPackageConf and Opt_Cpp gone in ghc 7.6.3? Cheers, -- Carlo ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Promoting Haskell via Youtube movies
On 18/06/13 04:23, Mihai Maruseac wrote: I was wondering if we have similar movies for Haskell as https://www.youtube.com/watch?v=kLO1djacsfg and https://www.youtube.com/watch?v=E3418SeWZfQ exist for Java. I indend to give them to some people to make them intrigued by the language and start learning it / looking for it. Not strictly on Haskell, but this on turned up on the Brisbane Functional Programmer Group's mailing list today: http://functionaltalks.org/ Cheers, -- Carlo Original Message Subject: [BFPG] Curated Functional Talks Blog Date: Tue, 18 Jun 2013 18:27:00 -0400 From: Ben Kolera ben.kol...@gmail.com Reply-To: bfpg-l...@meetup.com To: bfpg-l...@meetup.com Heya, Saw this float by on twitter and thought that it looked interesting for the group. http://functionaltalks.org/ Is a new blog full of curated talks on FP. The ones up there already are good talks (some from familiar BFPG faces :) that are definitely worth watching if you haven't already. If you want to follow along as more talks are added, there is an RSS feed here: http://functionaltalks.org/feed/ or you can also just follow @FunctionalTalks on twitter instead if that is preferred. Enjoy! Cheers, Ben ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] mapFst and mapSnd
On Tue, May 28, 2013 at 7:46 PM, Dominique Devriese dominique.devri...@cs.kuleuven.be wrote: 2013/5/28 Tikhon Jelvis tik...@jelv.is: These are present in Control.Arrow as (***), first and second respectively. Right, thanks. Strange that neither Hayoo nor Hoogle turned these up.. HLint suggested Control.Arrow. and Control.Arrow.first to me the other day: $ hlint Checker.hs Checker.hs:65:5: Warning: Reduce duplication Found: topdir - ask md5file - computeChecksumFilename f hasChecksum - liftM not $ isChecksumMissing f Why not: Combine with Checker.hs:81:5 Checker.hs:127:96: Warning: Use Found: \ x - (s3Path x, s3Md5sum x) Why not: s3Path Control.Arrow. s3Md5sum Checker.hs:153:42: Warning: Use first Found: \ (x, y) - (trimPathPrefix path x, y) Why not: Control.Arrow.first (trimPathPrefix path) 3 suggestions Some people that I know have HLint incorporated into their vim sessions, I think using Syntastic. Cheers, -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Need some advice around lazy IO
On Sun, Mar 17, 2013 at 3:08 PM, C K Kashyap ckkash...@gmail.com wrote: It's a small snippet and I've put in the comments stating how I run into out of file handles or simply file not getting read due to lazy IO. I realize that putting ($!) using a trial/error approach is going to be futile. I'd appreciate some pointers into the tools I could use to get some idea of which expressions are building up huge thunks. Have you tried System.IO.Strict's readFile? I had similar problems (too many file handles) and fixed it with import qualified System.IO.Strict as S and then using S.readFile instead of the standard prelude's readFile. This is where I used the strict IO readFile in my toy project: https://github.com/carlohamalainen/checker/blob/master/Checker.hs -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] simple parsec question
On Mon, Mar 4, 2013 at 1:44 AM, Immanuel Normann immanuel.norm...@googlemail.com wrote: I am trying to parse a semi structured text with parsec that basically should identify sections. Each section starts with a headline and has an unstructured content - that's all. Here's my attempt: https://gist.github.com/carlohamalainen/5087207 {-# LANGUAGE FlexibleContexts #-} import Text.Parsec import Control.Applicative hiding ((|),many) -- Example input: {- top 1: some text ... bla top 2: more text ... bla bla -} data Top = Top String deriving (Show) data Content = Content [String] deriving (Show) data Section = Section Top Content deriving (Show) headline = do t - many1 (noneOf :\n) char ':' newline return $ Top t contentLine = do x - many (noneOf :\n) newline return x content = do line - optionMaybe (try contentLine) case line of Just x - do xs - content return (x:xs) _ - return [] section = do h - headline c - Content $ content return $ Section h c main = do x - readFile simple.txt print $ parse (many section) x Example run using your sample data: $ runhaskell Simple.hs Right [Section (Top top 1) (Content [,some text ... bla,]),Section (Top top 2) (Content [,more text ... bla bla,])] Notes: * I had to assume that a content line does not contain a ':', because that is the only way to distinguish a head-line (correct me if I'm wrong). * The key was to use optionMaybe along with try; see the definition of content. * I haven't tested this code on very large inputs. * I slightly changed the definition of Content to have a list of Strings, one for each line. I'm sure this could be altered if you wanted to retain all whitespace. * I am still new to Parsec, so don't take this as the definitive answer ;-) -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] derivatives and integrals
On Wed, Feb 27, 2013 at 3:24 PM, Christopher Howard christopher.how...@frigidcode.com wrote: I'm not sure what is the best one to start with. I was wondering if there is anyone on this list who uses free software to do that sort of simpler Calc stuff, and what it is that they use. Not sure about any Haskell-based systems, but I can recommend Sage, a Python-based mathematics software system, which includes Maxima: http://sagemath.org/ -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] FFI - Approaches to C/C++
On Tue, Feb 5, 2013 at 1:56 PM, kudah kudahkuka...@gmail.com wrote: I'd object to your implication that Haskell is completely ready for use in general soft real-time systems. I was unable to implement a multi-threaded application which does a some IO-work in background threads in a way so that its GUI won't die. Worker threads simply starve the GUI, because Haskell doesn't have thread priorities. And even if it had, it would still lag on Windows, due to lack of IO manager. Ezyang had, in fact, made a new scheduler, which seems to address the problem; and joeyadams tries to make IO-manager for windows, but all this isn't going to see the light of day for a while, at least until 7.8.1. What did you use for the GUI? WxWidgets? I'm interested in this case because I develop a cross-platform Python GUI application and would like to see how a Haskell implementation would behave. -- Carlo Hamalainen http://carlo-hamalainen.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe