[Haskell-cafe] Re: iteratee: Do I need to roll my own?

2010-03-31 Thread Valery V. Vorotyntsev
I'm looking at iteratee as a way to replace my erroneous and really inefficient lazy-IO-based backend for an expect like Monad DSL I've been working for about 6 months or so now on and off. The problem is I want something like: expect some String send some response to block or perhaps

Re: [Haskell-cafe] cabal through PHPProxy

2010-03-31 Thread Valery V. Vorotyntsev
i'm using PHPProxy to go on the internet (www.phpproxy.fr). How can i tell cabal to use this? ... PHPProxy is a web based proxy. To use it, you have to type the http address you want in a field on the page. You still need some web access in order to access a web-based proxy... Is

Re: [Haskell-cafe] Takusen and iteratee problem

2010-03-20 Thread Valery V. Vorotyntsev
Today I stuck with the following problem: I want to read a file with iteratee package, and but it to database through Takusen package, but it doesn't work. The `Takusen` was built with `mtl` package, and `iteratee` - with `transformers`, so they are conflicting when used simultaneously. And

Re: [Haskell-cafe] Cabal update problem

2010-02-19 Thread Valery V. Vorotyntsev
after updating to cabal-install-0.8.0/Cabal-1.8.0.2 with GHC 6.10.4, I always get an error when updating the package list:   cabal update   Downloading the latest package list from hackage.haskell.org   cabal: Codec.Compression.Zlib: premature end of compressed stream Would you please send

Re: [Haskell-cafe] Iteratee, parsec co.

2010-02-09 Thread Valery V. Vorotyntsev
| 3. Why Seek FileOffset is error message? Are you talking about John Lato's implementation [1]? Well, `Seek' is not an error message. It is one of constructors for ErrMsg, and ErrMsg is [2] ---- a message to the stream producer (e.g., to rewind the stream) -- or an error

Re: [Haskell-cafe] safe lazy IO or Iteratee?

2010-02-05 Thread Valery V. Vorotyntsev
John Lato jwl...@gmail.com wrote: Both designs appear to offer similar performance in aggregate, although there are differences for particular functions. I haven't yet had a chance to test the performance of the CPS variant, although Oleg has indicated he expects it will be higher.

Re: [Haskell-cafe] mtl and transformers

2010-01-11 Thread Valery V. Vorotyntsev
Bas van Dijk v.dijk@gmail.com wrote: I always make a ghci.sh bash script in each of my projects that calls ghci -hide-all-packages -package x -package y -package z. However a cabal ghci or cabal interactive command that does this automatically would be ideal. I see there already is a

Re: [Haskell-cafe] mtl and transformers

2010-01-10 Thread Valery V. Vorotyntsev
Günther Schmidt: Could not find module `Control.Monad.Trans': it was found in multiple packages: transformers-0.1.4.0 mtl-1.1.0.2 Ivan Lazar Miljenovic: There's a way of specifying it at the top of whichever file you're using, but so far my workaround in this situation is to use

Re: [Haskell-cafe] Continuable and serializable parsers.

2009-12-25 Thread Valery V. Vorotyntsev
Serguey Zefirov sergu...@gmail.com wrote: 1) How to write a parser that could be restarted? Like, it will be represented by a function that returns something along the lines data ParseStepResult input result = Success (Maybe (input - ParseStepResult input result)) (Maybe result) |

[Haskell-cafe] changelogs for packages on Hackage

2009-12-16 Thread Valery V. Vorotyntsev
It would be nice if Hackage displayed ``recent changes'' of a package. [severity: wishlist] You see, I am subscribed to the ``hackage - recent additions'' feed [http://hackage.haskell.org/packages/archive/recent.rss] and receive entries that look like this: Cabal 1.8.0.2 Added by

Re: [Haskell-cafe] changelogs for packages on Hackage

2009-12-16 Thread Valery V. Vorotyntsev
Valery V. Vorotyntsev wrote: It would be nice if Hackage displayed ``recent changes'' of a package. [severity: wishlist] You see, I am subscribed to the ``hackage - recent additions'' feed [http://hackage.haskell.org/packages/archive/recent.rss] and receive entries that look like

[Haskell-cafe] Re: Iteratee question

2009-11-26 Thread Valery V. Vorotyntsev
On Thu, Nov 26, 2009 at 10:17 AM, o...@okmij.org wrote: You are correct: i2 and i3 can process a chunk of elements at a time, if an enumerator supplies it. That means an iteratee like i2 or i3 can do more work per invocation -- which is always good. Since you have to get the results as a

[Haskell-cafe] Re: Iteratee question

2009-11-26 Thread Valery V. Vorotyntsev
On Fri, Nov 27, 2009 at 4:04 AM, John Lato jwl...@gmail.com wrote: My apologies for not replying; I have been traveling and am only now working through my email. Oleg's response is much better than anything I would have written. I'd like to add one point. stream2list is very inefficient as

Re: [Haskell-cafe] haskell-mode.el mailing list (+ dpatch)

2009-11-25 Thread Valery V. Vorotyntsev
On Wed, Nov 25, 2009 at 10:37 AM, Svein Ove Aas svein@aas.no wrote: http://trac.haskell.org/haskellmode-emacs/ http://projects.haskell.org/cgi-bin/mailman/listinfo/haskellmode-emacs Hurray! Thanks, Svein. -- vvv ___ Haskell-Cafe mailing list

[Haskell-cafe] haskell-mode.el mailing list (+ dpatch)

2009-11-24 Thread Valery V. Vorotyntsev
Is there anybody except me feeling the need for mailing list and issue tracker for emacs' haskell-mode? Mailing list is a forum to discuss ideas _and_ the area of patch authors' self-advertisement. And issue tracker is a TODO list; it may be useful or annoying, and I think we can live without one

[Haskell-cafe] Re: haskell-mode.el mailing list (+ dpatch)

2009-11-24 Thread Valery V. Vorotyntsev
-- Description of the attached dpatch:  * make `inferior-haskell-find-project-root' respect export lists No joke this time. Sorry for the glitch. -- vvv Tue Nov 24 23:48:05 EET 2009 Valery V. Vorotyntsev valery...@gmail.com * make `inferior-haskell-find-project-root' respect export lists

[Haskell-cafe] Iteratee question

2009-11-20 Thread Valery V. Vorotyntsev
I am writing a binary data parser and use `iteratee' package. The following pattern appears quite often in my code: results - map someConversion `liftM` replicateM nbytes Iter.head The meaning is: take `nbytes' from stream, apply `someConversion' to every byte and return the list of `results'.

[Haskell-cafe] Fwd: cabal-install sends invalid proxy password

2008-12-17 Thread Valery V. Vorotyntsev
Hello, I was surprised to discover that `cabal-install' -- a popular utility for installing Hackage packages -- cannot work with HTTP proxies. Despite all the necessary code linked in. `cabal update' command returns HTTP 407 (Proxy Authentication Required) error. The problem is explained

[Haskell-cafe] Re: Arrow without `'

2008-01-24 Thread Valery V. Vorotyntsev
On 1/23/08, David Menendez [EMAIL PROTECTED] wrote: On Jan 23, 2008 12:20 PM, Valery V. Vorotyntsev [EMAIL PROTECTED] wrote: I've built GHC from darcs, and... Could anybody tell me, what's the purpose of Arrow[1] not having `' method? It's derived from the Category superclass. Yes

[Haskell-cafe] Fwd: Arrow without `'

2008-01-24 Thread Valery V. Vorotyntsev
The problem has been resolved. Kudos to Ross Paterson. -- Forwarded message -- From: Valery V. Vorotyntsev [EMAIL PROTECTED] Date: Jan 24, 2008 3:34 PM Subject: Re: Arrow without `' To: [EMAIL PROTECTED] On 1/24/08, Ross Paterson [EMAIL PROTECTED] wrote: The right question: how

[Haskell-cafe] Arrow without `'

2008-01-23 Thread Valery V. Vorotyntsev
Hi, friends, I've built GHC from darcs, and... Could anybody tell me, what's the purpose of Arrow[1] not having `' method? 1. http://darcs.haskell.org/packages/base/Control/Arrow.hs $ ghci GHCi, version 6.9.20080104: http://www.haskell.org/ghc/ :? for help Loading package base ...

Re: [Haskell-cafe] Code folding in Emacs

2008-01-14 Thread Valery V. Vorotyntsev
On 1/14/08, Johan Tibell [EMAIL PROTECTED] wrote: It would be pretty neat for Haskell hacking if the Emacs Haskell mode could do the following. Imagine you have written some code like so: [...] Binding a haskell-fold-source function to a key chain would enable you to get a quick overview of

Re: [Haskell-cafe] Literate HTML

2007-12-11 Thread Valery V. Vorotyntsev
On 12/11/07, Neil Mitchell [EMAIL PROTECTED] wrote: I couldn't get it working either, so have raised a feature request bug. Which has been merged into #1232: http://hackage.haskell.org/trac/ghc/ticket/1967#comment:1 -- vvv ___ Haskell-Cafe mailing

[Haskell-cafe] Re: emacs haskellers: r-stripping files becomes popular

2007-11-16 Thread Valery V. Vorotyntsev
On 11/16/07, Valery V. Vorotyntsev [EMAIL PROTECTED] wrote: Add the following lines to your ~/.emacs: Adding buffer name to confirmation message: --- BEGIN --- (defun delete-trailing-whitespace-if-confirmed () Delete all the trailing whitespace across the current buffer, asking user

Re: [Haskell-cafe] emacs haskellers: r-stripping files becomes popular

2007-11-16 Thread Valery V. Vorotyntsev
On 11/16/07, Denis Bueno [EMAIL PROTECTED] wrote: For one thing, if you happen to write code shared with other people who do not use this hook, then you may end up causing *huge* numbers of spurious differences in diff(1) output. There may be an easy way to deal with this, but, it is a

Re: [Haskell-cafe] emacs haskellers: r-stripping files becomes popular

2007-11-16 Thread Valery V. Vorotyntsev
On 11/16/07, Brent Yorgey [EMAIL PROTECTED] wrote: Nice! Is there a way to have this only run if the current buffer is in haskell-mode? I'd add it myself but I've not yet taken the plunge to being an elisp hacker. Try adding ``(eq major-mode 'haskell-mode)'' after the `and' .. .. but why

[Haskell-cafe] emacs haskellers: r-stripping files becomes popular

2007-11-16 Thread Valery V. Vorotyntsev
Add the following lines to your ~/.emacs: --- BEGIN OF ELISP CODE --- ;(global-set-key (kbd f9 s) 'delete-trailing-whitespace) (defun delete-trailing-whitespace-if-confirmed () Delete all the trailing whitespace across the current buffer, asking user for confirmation. (if (and

Re: [Haskell-cafe] ANN: Math.OEIS 0.1

2007-10-22 Thread Valery V. Vorotyntsev
On 10/22/07, Henning Thielemann [EMAIL PROTECTED] wrote: Cute! +1 http://programming.reddit.com/info/5yuhf/comments/ -- vvv ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] On the verge of ... giving up!

2007-10-19 Thread Valery V. Vorotyntsev
On 10/19/07, Valery V. Vorotyntsev [EMAIL PROTECTED] wrote: On 10/19/07, Johan Tibell [EMAIL PROTECTED] wrote: If you have a web server somewhere you can use CGIIRC. That's what I did in a similar situation. http://cgiirc.org/ Thanks, Johan! There is one at http://ircatwork.com

Re: [Haskell-cafe] On the verge of ... giving up!

2007-10-19 Thread Valery V. Vorotyntsev
On 10/18/07, Don Stewart [EMAIL PROTECTED] wrote: Please drop by the irc channel! enthusiasm is always welcome there, and we're pretty much all obsessed too! Maybe that's not The Right Thing(TM) to ask, but anyway. :) My access the world outside the office's LAN is limited to ports 80 and

Re: [Haskell-cafe] 'Proper' use of the State monad

2007-05-03 Thread Valery V. Vorotyntsev
Denis Volk [EMAIL PROTECTED] writes: I am trying to make a (turn-based) game in Haskell and need to pass around quite a bit of information, so using the State monad seems most appropriate. My question is, which is a better idea: Have you read `Theseus and the Zipper'[1] yet? 1.

Re: [Haskell-cafe] Why Perl is more learnable than Haskell

2007-04-12 Thread Valery V. Vorotyntsev
Dave Feustel [EMAIL PROTECTED] writes: A serious omission in Haskell tutorials is a collection of examples of how to write Haskell solutions for problems that would use arrays in any imperative language. I see that arrays can be defined in Haskell, but I don't see their use as

Re: [OT] Re: [Haskell-cafe] Tricks for making low level haskell hacking easier

2007-03-05 Thread Valery V. Vorotyntsev
Mathieu Boespflug [EMAIL PROTECTED] writes: On 2/10/07, Donald Bruce Stewart [EMAIL PROTECTED] wrote: metachars). A screenshot: http://www.cse.unsw.edu.au/~dons/tmp/screen-core.png Just out of curiosity, what window manager is that? Mathieu Looks like ratpoison.