[Haskell-cafe] haskell; json-rpc

2011-07-05 Thread Комар Максим
Apologize in advance for the English language. I'm working with json-rpc interface (http://json-rpc.org/) via http. Requests and responses look like this: - {jsonrpc : 2.0, id : 1, method : user.authenticate, params : { user : myUser, password : myPassword }} -

Re: [Haskell-cafe] video for linux two (v4l2) bindings

2011-07-05 Thread Christopher Done
On 3 July 2011 21:46, Daniel Fischer daniel.is.fisc...@googlemail.com wrote: On Sunday 03 July 2011, 21:34:17, Christopher Done wrote: I just had a quick try with cabal-install and got the below. I'm not sure where linux/posix_types is supposed to come from. Is this error obvious to you?

Re: [Haskell-cafe] Haskell and Databases

2011-07-05 Thread Isak Hansen
On Fri, Jul 1, 2011 at 8:45 PM, Tobias Schoofs tobias.scho...@gmx.net wrote: Database programs, usually, do not just issue isolated SQL statements, but implement a processing logic with nested queries and DML statements. Frequently using cursors or issuing queries from a loop often means

Re: [Haskell-cafe] Splitting Hackage Packages and re-exporting entire modules (with same module name)

2011-07-05 Thread Antoine Latter
If you give the module a new name in the new package then the old module can re-export all of the symbols in the new module. In GHC I don't think there is a way for two packages to export the same module and have them be recognized as the same thing, as far as I know. Antoine On Tue, Jul 5,

Re: [Haskell-cafe] NVIDIA's CUDA and Haskell

2011-07-05 Thread Trevor L. McDonell
I should mention that the version of 'accelerate' on hackage is a little old and unloved at the moment, but the source repo should work: https://github.com/mchakravarty/accelerate Also, the CUDA bindings package hasn't yet been tested/updated for the recent 4.0 toolkit release. -T On

Re: [Haskell-cafe] NVIDIA's CUDA and Haskell

2011-07-05 Thread Johannes Waldmann
Trevor L. McDonell tmcdonell at cse.unsw.edu.au writes: ... source repo should work: https://github.com/mchakravarty/accelerate I have CUDA in the default location (e.g., /usr/local/cuda/bin/nvcc ) but I can't seem to get the cuda cabal package to build ... checking cuda.h usability... yes

Re: [Haskell-cafe] Automatic Reference Counting

2011-07-05 Thread Maarten Hazewinkel
On 2 Jul 2011, at 18:35, Thomas Davie wrote: It's interesting that you cite that GC is both faster and lower memory overhead – Apple's stated reasons for implementing this were that GC was both too slow and too memory intensive to use sensibly on iDevices and that ARC was both faster and

[Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Tillmann Vogt
Hi, For my font library I need A function that can handle ligatures. It can be explained best with an example: f [Th, ff, fi, fl, ffi] The fluffiest bunny should be evaluated to [Th, e, , fl, u, ffi, e, s, t, , b, u, n, n, y ] I looked at Data.Text

Re: [Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Johannes Waldmann
... a function that can search several substrings in one run. use regular expressions? (the regexp can be compiled into a finite automaton that scans the string just once.) ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

Re: [Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Daniel Fischer
On Tuesday 05 July 2011, 20:01:26, Tillmann Vogt wrote: Hi, For my font library I need A function that can handle ligatures. It can be explained best with an example: f [Th, ff, fi, fl, ffi] The fluffiest bunny should be evaluated to [Th, e, , fl, u, ffi, e, s, t, , b, u, n, n,

Re: [Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Bryan O'Sullivan
On Tue, Jul 5, 2011 at 11:01 AM, Tillmann Vogt tillmann.v...@rwth-aachen.de wrote: I looked at Data.Text http://hackage.haskell.org/** packages/archive/text/0.5/doc/**html/Data-Text.htmlhttp://hackage.haskell.org/packages/archive/text/0.5/doc/html/Data-Text.html and

Re: [Haskell-cafe] How to ensure code executes in the context of a specific OS thread?

2011-07-05 Thread Simon Marlow
On 04/07/11 06:02, Jason Dagit wrote: Hello, I'm trying to get some GUI code working on OSX and numerous forums around the internet keep reiterating that on OSX to correctly handle GUI events you need to use the original thread allocated to your process to check for events and to call the Cocoa

Re: [Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Eric Rasmussen
I've been looking into building parsers at runtime (from a config file), and in my case it's beneficial to fit them into the context of a larger parser with Attoparsec.Text. This code is untested for practical use so I doubt you'll see comparable performance to the aforementioned regex packages,

Re: [Haskell-cafe] How to ensure code executes in the context of a specific OS thread?

2011-07-05 Thread Ian Lynagh
On Tue, Jul 05, 2011 at 08:11:21PM +0100, Simon Marlow wrote: In GHCi it's a different matter, because the main thread is running GHCi itself, and all the expressions/statements typed at the prompt are run in forkIO'd threads (a new one for each statement, in fact). If you want a way to run

Re: [Haskell-cafe] How to ensure code executes in the context of a specific OS thread?

2011-07-05 Thread Jason Dagit
On Tue, Jul 5, 2011 at 12:11 PM, Simon Marlow marlo...@gmail.com wrote: On 04/07/11 06:02, Jason Dagit wrote: Hello, I'm trying to get some GUI code working on OSX and numerous forums around the internet keep reiterating that on OSX to correctly handle GUI events you need to use the

[Haskell-cafe] ANNOUNCE: test-framework-doctest 0.1

2011-07-05 Thread Sakari Jokinen
test-framework-doctest [1] provides a wrapper for running doctests [2] in test-framework [3]. This uses the newly minted API exposed by doctest 0.4 that Simon Hengel just announced [4]. The current incarnation of the package is a very rudimentary. Patches are more than welcome [5]. Many thanks

[Haskell-cafe] ANN: Monad.Reader Issue 18

2011-07-05 Thread Brent Yorgey
I am pleased to announce that Issue 18 of The Monad.Reader is now available [1]. Issue 18 consists of the following three articles: * MapReduce as a Monad by Julian Porter * Fun with Parallel Monad Comprehensions by Tomas Petricek * Attributed Variables: Their Uses and One Implementation

Re: [Haskell-cafe] Searching of several substrings (with Data.Text ?)

2011-07-05 Thread Tillmann Vogt
Am 05.07.2011 21:29, schrieb Eric Rasmussen: I've been looking into building parsers at runtime (from a config file), and in my case it's beneficial to fit them into the context of a larger parser with Attoparsec.Text. This code is untested for practical use so I doubt you'll see comparable

Re: [Haskell-cafe] How to ensure code executes in the context of a specific OS thread?

2011-07-05 Thread Jason Dagit
On Tue, Jul 5, 2011 at 12:33 PM, Ian Lynagh ig...@earth.li wrote: On Tue, Jul 05, 2011 at 08:11:21PM +0100, Simon Marlow wrote: In GHCi it's a different matter, because the main thread is running GHCi itself, and all the expressions/statements typed at the prompt are run in forkIO'd threads

[Haskell-cafe] ANNOUNCE: FunPat 0.1

2011-07-05 Thread Dévai Gergely
Hello, I've recently uploaded a package that provides some kind of extended pattern matching. For example, one can use (abc ++ xs) as a pattern. The original motivation was to allow pattern matching on expressions of embedded languages in cases when the constructors of the underlying data

Re: [Haskell-cafe] NVIDIA's CUDA and Haskell

2011-07-05 Thread Trevor L. McDonell
hmm... so libcuda and libcudart are in /usr/local/cuda/lib and the script isn't finding them? Any further information on your system / os combination? What version of the toolkit are you using? I currently use 3.2, haven't tried with 4.x yet. $ nvcc --version nvcc: NVIDIA (R) Cuda compiler

Re: [Haskell-cafe] Automatic Reference Counting

2011-07-05 Thread steffen
The important point about reference counting on idevices is the near realtime performance, since stops for collecting garbage are actually very short in comparison to collecting compilers (despite more frequent). Some compilers, I think it was for the pure functional programming language OPAL