Re: [Haskell-cafe] Looking for pointfree version

2009-02-15 Thread Conal Elliott
And then to down = mconcat [downPar, downNew, downTrans] Which is pretty cute considering that the original formulation is equivalent to and a tiny tweak away from down p = mconcat [downPar p, downNew p, downTrans p] Hooray for Monoid! - Conal On Mon, Feb 9, 2009 at 6:31 AM, Wouter

Re: [Haskell-cafe] Amazing

2009-02-15 Thread Conal Elliott
Hi Peter, I'm delighted to hear about your successes with Haskell programming! I suspect that parametric polymorphism has a lot to do with phenomenon of works-when-it-compiles. The more polymorphic a signature is, the fewer the possible type-correct definitions. Luckily, the definition that "wo

Re: [Haskell-cafe] Help needed with apache config for hackage

2009-02-15 Thread George Pollard
On Fri, 2009-02-13 at 22:39 +1100, George Pollard wrote: > RewriteRule "^packages/archive/[^/]+/[^/]+/(.+)$" - [env=pkgname:$1] This should actually be more constrained since (as I've just noticed) more than just packages are under this path :) Perhaps: > RewriteRule "^packages/archive/[^/]+/[^

[Haskell-cafe] Re: ANNOUNCE: spacepart-0.1.0.0 (was called data-spacepart)

2009-02-15 Thread Corey O'Connor
(Omitted some useful information from original emails. Oops!) Space partition data structures. Currently only a quadtree. http://hackage.haskell.org/cgi-bin/hackage-scripts/package/spacepart On Sun, Feb 15, 2009 at 7:28 PM, Corey O'Connor wrote: > 0.1.0.0 >- Renamed Math.Geometry to Data.Sp

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
Okay, I tested it out and the arrow transformer has the same problem. I realized this after I sent the last message -- the point is that at any particular point, intuitively there should be exactly one copy of a State# s for each state thread, and it should never get duplicated; allowing other mon

[Haskell-cafe] ANNOUNCE: spacepart-0.1.0.0 (was called data-spacepart)

2009-02-15 Thread Corey O'Connor
0.1.0.0 - Renamed Math.Geometry to Data.SpacePart.AABB - Renamed Data.QuadTree to Data.SpacePart.QuadTree - Added Data.SpacePart.QuadTree.query. Returns all elements that intersect a given boundary. - The inclusive nature of the boundary's min extent should take precedence of the ex

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Dan Doel
On Sunday 15 February 2009 9:44:42 pm Louis Wasserman wrote: > Hello all, > > I just uploaded stateful-mtl and pqueue-mtl 1.0.1. The ST monad > transformer and array transformer have been removed -- I've convinced > myself that a heap transformer backed by an ST array cannot be > referentially tra

Re: [Haskell-cafe] Interactive debugging?

2009-02-15 Thread Brandon S. Allbery KF8NH
On 2009 Feb 15, at 15:22, Colin Paul Adams wrote: Can this be done with Haskell? In particular, I'm using ghc 6.10.1. Can I get symbols for use with gdb, for instance gdb would be extremely painful; the flow of execution in lazy languages is unusual. ghci from 6.8.1 on has an interactive de

Re: [Haskell-cafe] Comparison of functional dependencies and type families [was: Re: Type families not as useful over functions]

2009-02-15 Thread Manuel M T Chakravarty
Just for the record, here a few clarifications. Expressiveness ~~ From a theoretical point of view, type families (TFs) and functional dependencies (FDs) are equivalent in expressiveness. There is nothing that you can do in one and that's fundamentally impossible in the other.

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
Hello all, I just uploaded stateful-mtl and pqueue-mtl 1.0.1. The ST monad transformer and array transformer have been removed -- I've convinced myself that a heap transformer backed by an ST array cannot be referentially transparent -- and the heap monad is now available only as a basic monad an

Re: [Haskell-cafe] Haddock Markup

2009-02-15 Thread Richard O'Keefe
On 15 Feb 2009, at 5:45 am, Wolfgang Jeltsch wrote: So you mean a language which * directly corresponds to a subset of MathML (and is therefore easily convertible into sensible MathML) * is at the same time valid TeX source which can be processed by TeX based on a few macro

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread wren ng thornton
Louis Wasserman wrote: I follow. The primary issue, I'm sort of wildly inferring, is that use of STT -- despite being pretty much a State monad on the inside -- allows access to things like mutable references? That's exactly the problem. The essential reason for ST's existence are STRefs whic

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
The module I put together already has everything I'd need to do it in terms of an IntMap with much less work than that -- the generic MonadArray type class has implementations both in terms of ST and in terms of an IntMap already. Only three changes in the Heap implementation would be needed: two

[Haskell-cafe] Parameterized monad transformers

2009-02-15 Thread Miran Lipovača
Howdy y'all! I was reading sigfpe's Beyond Monads post (http://blog.sigfpe.com/2009/02/beyond-monads.html) about parameterized monads. Great post, makes you go: this is so elegant and simple, why didn't I think of that? Anyway, I was wondering whether those monads have corresponding transform

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Ryan Ingram
You can roll your own pure STT monad, at the cost of performance: -- Do not export any of these constructors, just the types STT and STTRef. data W = forall a. W !a data Heap s = Heap !Int !(IntMap W) newtype STT s m a = STT (StateT (Heap s) m a) deriving (Monad, MonadTrans, MonadIO, insert other

Re: [Haskell-cafe] forall & ST monad

2009-02-15 Thread Luke Palmer
2009/2/15 Brandon S. Allbery KF8NH > On 2009 Feb 15, at 11:50, Peter Verswyvelen wrote: > > I could try to read the article a couple of times again, but are there any > other good readings about these existentially quantified types and how the > ST monad works? > > > You could think about it as p

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
Well, it makes me sad, I guess. pqueue-mtl provides an array-backed heap monad transformer that is supposed to keep its own ST thread, if only for the sake of retaining a purely functional interface without any externally visible forall'd types, which is perfectly fine in most cases, but I'd have

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Henning Thielemann
On Sun, 15 Feb 2009, Louis Wasserman wrote: I follow.  The primary issue, I'm sort of wildly inferring, is that use of STT -- despite being pretty much a State monad on the inside -- allows access to things like mutable references? I assume that ST must always be the most inner monad, like

Re: [Haskell-cafe] forall & ST monad

2009-02-15 Thread Henning Thielemann
Peter Verswyvelen schrieb: > I'm having trouble understanding the explanation of the meaning of the > signature of runST at > > http://en.wikibooks.org/wiki/Haskell/Existentially_quantified_types Is this one better http://haskell.org/haskellwiki/Monad/ST ? ___

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
I follow. The primary issue, I'm sort of wildly inferring, is that use of STT -- despite being pretty much a State monad on the inside -- allows access to things like mutable references? More serious question: The issue of nondeterministic branching and the State monad is something that's occurre

Re: [Haskell-cafe] The wheather is ⊥

2009-02-15 Thread Neil Bartlett
It depends whether that's NaN ºC or NaN ºF. 2009/2/15 Fraser Wilson : > Is that really cold or really hot? > > On Sun, Feb 15, 2009 at 11:27 PM, Henk-Jan van Tuyl > wrote: >> >> The temperature is now NaN°: >> http://traviswalters.net/?p=58 >> >> -- >> Met vriendelijke groet, >> Henk-Jan van Tuy

[Haskell-cafe] Need some ideas to map XML Schema types to Haskell types

2009-02-15 Thread Praki Prakash
Hi, I need to work with a web service that has a few thousand types in its schema. I am trying to automate the generation of data types and serializers from the schema. My first thought was to map each data type to a Haskell record and generate pickle methods thereafter for serialziation/deseriali

Re: [Haskell-cafe] The wheather is ⊥

2009-02-15 Thread Fraser Wilson
Is that really cold or really hot? On Sun, Feb 15, 2009 at 11:27 PM, Henk-Jan van Tuyl wrote: > > The temperature is now NaN°: > http://traviswalters.net/?p=58 > > -- > Met vriendelijke groet, > Henk-Jan van Tuyl > > > -- > http://functor.bamikanarie.com > http://Van.Tuyl.eu/ > -- > > >

[Haskell-cafe] The wheather is ⊥

2009-02-15 Thread Henk-Jan van Tuyl
The temperature is now NaN°: http://traviswalters.net/?p=58 -- Met vriendelijke groet, Henk-Jan van Tuyl -- http://functor.bamikanarie.com http://Van.Tuyl.eu/ -- ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailma

Re: [Haskell-cafe] forall & ST monad

2009-02-15 Thread Ryan Ingram
On Sun, Feb 15, 2009 at 11:50 AM, Kim-Ee Yeoh wrote: > Having said that, I'm not sure about the statement on page 9 > that "readVar v simply does not have type forall s. ST s Bool." > The variable v could be of type "forall s. MutVar s Bool", > in which case all of "runST (readVar v)" typechecks.

Re: [Haskell-cafe] Re: Amazing

2009-02-15 Thread Lennart Augustsson
It's true that you can do "program" the type checker even more if you have dependent types, but first you should look into what you can do in Haskell. You can do a lot with type classes. -- Lennart 2009/2/15 Peter Verswyvelen : > How practical is this dependent types thing? I hear a lot about

Re: [Haskell-cafe] Epic failure

2009-02-15 Thread Don Stewart
> OK, what did I do wrong here? When making a request for help on a compiler issue, you failed to include key information to make it possible to reproduce your problem, and what you did include was broken or incorrect. The three programs that submitted don't do even do the same thing. Let's look

Re: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Reid Barton
On Sun, Feb 15, 2009 at 09:59:28PM -, Sittampalam, Ganesh wrote: > > Stateful-mtl provides an ST monad transformer, > > Is this safe? e.g. does it work correctly on [], Maybe etc? > > If not this should be flagged very prominently in the documentation. It is not safe: it has the same proble

[Haskell-cafe] Epic failure

2009-02-15 Thread Andrew Coppin
OK, what did I do wrong here? module Main () where import Data.List top = 10 ^ 8 :: Int main = do let numbers = [1 .. top] print $ foldl' (+) 0 numbers -- Runtime is 20 seconds. #include int main(void) { int total = 0; int n; for (n = 1, n < 1; n++) total += n; printf(

[Haskell-cafe] Help with Stack Space Overflow / Memory Issues

2009-02-15 Thread Travis B. Hartwell
Hello, I'm writing a small program to process Delicious [1] RSS feeds. I like look at the recent feeds to see what others have bookmarked recently. But, there are a lot of duplicates in the recent feeds as an entry is shown for each person who bookmarks an individual URL. I decided to write a sm

Re: [Haskell-cafe] Low-level high-level languages?

2009-02-15 Thread Peter Verswyvelen
You might want to take a look at Timber http://www.timber-lang.org On Sun, Feb 15, 2009 at 6:22 PM, Maurí­cio wrote: > Hi, > > I've checked this 'BitC' language (www.bitc-lang.org). It > uses some ideas we see in Haskell, although with different > realization, and target mainly reliable low lev

Re: [Haskell-cafe] Re: Amazing

2009-02-15 Thread Peter Verswyvelen
How practical is this dependent types thing? I hear a lot about this from really clever people who are usually 10 years ahead of their time :) Actually, back in the eighties when I was an assembly language hacker, I didn't want to switch to Pascal or C since I found the types in those languages too

RE: [Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Sittampalam, Ganesh
> Stateful-mtl provides an ST monad transformer, Is this safe? e.g. does it work correctly on [], Maybe etc? If not this should be flagged very prominently in the documentation. Cheers, Ganesh == Please access the att

Re: [Haskell-cafe] Re: Amazing

2009-02-15 Thread Lennart Augustsson
This must be why there are no good compilers for dependently typed languages. :) On Sun, Feb 15, 2009 at 9:40 PM, Stefan Monnier wrote: >> So IMO static typing is good, but it's only with functional programming that >> it really shines. > > You can go one step further: if you start using dependen

Re: Re: [Haskell-cafe] Looking for pointfree version

2009-02-15 Thread Kim-Ee Yeoh
> import Control.Applicative > > data Pair a = a :*: a > > instance Functor Pair where > f `fmap` (x :*: y) = f x :*: f y > > instance Applicative Pair where > (f :*: g) <*> (x :*: y) = f x :*: f y The last f needs to be a g. > pure x = x :*: x > > pointfree :: (a -> b -> c

[Haskell-cafe] Re: Amazing

2009-02-15 Thread Stefan Monnier
> So IMO static typing is good, but it's only with functional programming that > it really shines. You can go one step further: if you start using dependent types, you'll see that it gets yet harder to get your program to type-check, and once it does, you don't even bother to run it since it's so

[Haskell-cafe] ANNOUNCE: pqueue-mtl, stateful-mtl

2009-02-15 Thread Louis Wasserman
Hello all, I just released two new packages on Hackage, stateful-mtl and pqueue-mtl. Stateful-mtl provides an ST monad transformer, several useful operations on generic monad transformers, and a monad transformer intended to cleanly externally wrap operations on a mutable array (including resizin

[Haskell-cafe] Interactive debugging?

2009-02-15 Thread Colin Paul Adams
Can this be done with Haskell? In particular, I'm using ghc 6.10.1. Can I get symbols for use with gdb, for instance? -- Colin Adams Preston Lancashire ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskel

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Derek Elkins
On Sun, 2009-02-15 at 18:53 +0100, Tillmann Rendel wrote: > Gregg Reynolds wrote: > > BTW, I'm not talking about Haskell's Functor class, I guess I should > > have made that clear. I'm talking about category theory, as the > > semantic framework for thinking about Haskell. > > In that case, I eve

Re: [Haskell-cafe] forall & ST monad

2009-02-15 Thread Kim-Ee Yeoh
Peter Verswyvelen-2 wrote: > > I could try to read the article a couple of times again, but are there any > other good readings about these existentially quantified types and how the > ST monad works? > The primary source is if I'm not mistaken, the following "State in Haskell" paper: http:/

Re: [Haskell-cafe] Help needed with apache config for hackage

2009-02-15 Thread Tristan Seligmann
* Duncan Coutts [2009-02-13 12:19:29 +]: > Can we do that just for one user agent? I don't think we want to use > non-standard stuff in general. Apparently Content-Disposition is not in > the official HTTP spec, but IE is known to follow it. Well, it's mentioned in RFC 2616[1], and I'd expec

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Svein Ove Aas
On Sun, Feb 15, 2009 at 7:54 PM, Svein Ove Aas wrote: > 2009/2/15 Gregg Reynolds : >> >> The metaphor is action-at-a-distance. Quantum entanglement is a vivid way >> of conveying it since it is so strange, but true. Obviously one is not >> expected to understand quantum entanglement, only the id

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Svein Ove Aas
2009/2/15 Gregg Reynolds : > > The metaphor is action-at-a-distance. Quantum entanglement is a vivid way > of conveying it since it is so strange, but true. Obviously one is not > expected to understand quantum entanglement, only the idea of two things > linked "invisibly" across a boundary. > Th

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Gregg Reynolds
On Sun, Feb 15, 2009 at 12:45 PM, Anton van Straaten wrote: > Gregg Reynolds wrote: > >> Action-at-a-distance is a metaphor meant to enliven the concept. >> > > Kind of like the container metaphor? > Yes, only, different. Non-pernicious. ;) ___ Haske

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Anton van Straaten
Gregg Reynolds wrote: Action-at-a-distance is a metaphor meant to enliven the concept. Kind of like the container metaphor? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Gregg Reynolds
On Sun, Feb 15, 2009 at 11:53 AM, Tillmann Rendel wrote: > Gregg Reynolds wrote: > >> BTW, I'm not talking about Haskell's Functor class, I guess I should >> have made that clear. I'm talking about category theory, as the >> semantic framework for thinking about Haskell. > > Don't forget the par

Re: [Haskell-cafe] forall & ST monad

2009-02-15 Thread Brandon S. Allbery KF8NH
On 2009 Feb 15, at 11:50, Peter Verswyvelen wrote: I could try to read the article a couple of times again, but are there any other good readings about these existentially quantified types and how the ST monad works? You could think about it as playing a dirty trick on the typechecker. Th

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread alpheccar
Quantum entanglement is related to a different kind of categorical product. So, the metaphor is misleading. But, that being said : I want to thank you for your blog. A bit polemic but very interesting. Christophe. Came up with an alternative to the container metaphor for functors that you

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Tillmann Rendel
Gregg Reynolds wrote: BTW, I'm not talking about Haskell's Functor class, I guess I should have made that clear. I'm talking about category theory, as the semantic framework for thinking about Haskell. In that case, I even less see why you are not introducing category theory proper. Certainly

Re: [Haskell-cafe] createProcess shutting file handles

2009-02-15 Thread Neil Mitchell
Hi >> > However the createProcess command structure has the close_fds flag, >> > which seems like it should override that behaviour, and therefore this >> > seems like a bug in createProcess. >> >> close_fds :: Bool >> >> Close all file descriptors except stdin, stdout and stderr i

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Gregg Reynolds
On Sun, Feb 15, 2009 at 11:09 AM, Tillmann Rendel wrote: > Gregg Reynolds wrote: > >> Came up with an alternative to the container metaphor for functors that >> you >> might find amusing: http://syntax.wikidot.com/blog:9 >> > > You seem to describe Bifunctors (two objects from one category are m

[Haskell-cafe] Low-level high-level languages?

2009-02-15 Thread Maurí­cio
Hi, I've checked this 'BitC' language (www.bitc-lang.org). It uses some ideas we see in Haskell, although with different realization, and target mainly reliable low level code, like micro-kernels (although I think it could be used anywhere C is also used, including writing libraries Haskell could

Re: [Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Tillmann Rendel
Gregg Reynolds wrote: Came up with an alternative to the container metaphor for functors that you might find amusing: http://syntax.wikidot.com/blog:9 You seem to describe Bifunctors (two objects from one category are mapped to one object in another category), but Haskell's Functor class is

[Haskell-cafe] Re: Race condition possible?

2009-02-15 Thread Achim Schneider
Peter Verswyvelen wrote: > "Time on different cores does not progress monotonically" Two cores executing the same code are not guaranteed to finish them in the same time span, due to caching, temperature, voltage jaggies, quantum-mechanic inference, ... -- (c) this sig last receiving data pro

[Haskell-cafe] forall & ST monad

2009-02-15 Thread Peter Verswyvelen
I'm having trouble understanding the explanation of the meaning of the signature of runST at http://en.wikibooks.org/wiki/Haskell/Existentially_quantified_types I could try to read the article a couple of times again, but are there any other good readings about these existentially quantified types

[Haskell-cafe] Intergalactic Telefunctors

2009-02-15 Thread Gregg Reynolds
Came up with an alternative to the container metaphor for functors that you might find amusing: http://syntax.wikidot.com/blog:9 ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Re: permuting a list

2009-02-15 Thread Paul Johnson
See http://okmij.org/ftp/Haskell/perfect-shuffle.txt Paul. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Re: [Haskell-cafe] Telnet handshaking

2009-02-15 Thread Martijn van Steenbergen
Krzysztof Skrzętnicki wrote: On Sun, Feb 15, 2009 at 10:25, Martijn van Steenbergen wrote: Are there any Haskell libraries out there that implement telnet? Bare sockets are a good approximation, but I'm looking for a library that understands the escape sequences specific to telnet. I think Yo

Re: [Haskell-cafe] createProcess shutting file handles

2009-02-15 Thread Duncan Coutts
On Sun, 2009-02-15 at 11:06 +, Duncan Coutts wrote: > On Sun, 2009-02-15 at 09:24 +, Neil Mitchell wrote: > > Hi > > > > >> What have I done wrong? Did createProcess close the handle, and is > > >> there a way round this? > > > > > > The docs for runProcess says: > > > > > >Any Han

Re: [Haskell-cafe] Help with Menu item handlers in gtk2hs with glade

2009-02-15 Thread Duncan Coutts
On Sun, 2009-02-15 at 16:48 +0530, Lakshmi Narasimhan wrote: > I designed a basic GUI with Menu bar and menu items in glade. I use the > glade bindings in haskell to get the menu item using xmlGetWidget and > castToMenuItem function. I set a *onActivateItem* handler for this > menuitem. However

[Haskell-cafe] Re: permuting a list

2009-02-15 Thread Heinrich Apfelmus
Felipe Lessa wrote: > Heinrich Apfelmus wrote: >> >> It's fair, but may duplicate elements, i.e. it doesn't necessarily >> create a permutation. For example, rs could be something like >> >> rs = [5,3,3,3,2,4] >> > > But our sort doesn't discard values when the keys are the same. For example,

Re: [Haskell-cafe] Telnet handshaking

2009-02-15 Thread Krzysztof Skrzętnicki
On Sun, Feb 15, 2009 at 10:25, Martijn van Steenbergen wrote: > Are there any Haskell libraries out there that implement telnet? Bare > sockets are a good approximation, but I'm looking for a library that > understands the escape sequences specific to telnet. I think Yogurt http://hackage.haskell

Re: [Haskell-cafe] Race condition possible?

2009-02-15 Thread Peter Verswyvelen
I'm not sure what you mean with "Time on different cores does not progress monotonically". Time could come from a dedicated clock device. E.g. in the broadcast television sector a time signal is distributed across all hardware components to keep them all in sync within some margin, or you could use

Re: [Haskell-cafe] Re: permuting a list

2009-02-15 Thread Felipe Lessa
On Sun, Feb 15, 2009 at 9:47 AM, Heinrich Apfelmus wrote: > It's fair, but may duplicate elements, i.e. it doesn't necessarily > create a permutation. For example, rs could be something like > > rs = [5,3,3,3,2,4] > But our sort doesn't discard values when the keys are the same. For example,

Re: [Haskell-cafe] Re: permuting a list

2009-02-15 Thread Alberto Ruiz
Heinrich Apfelmus wrote: Jon Fairbairn wrote: Heinrich Apfelmus writes: The answer is a resounding "yes" and the main idea is that shuffling a list is *essentially the same* as sorting a list; the minor difference being that the former chooses a permutation at random while the latter chooses a

[Haskell-cafe] Re: permuting a list

2009-02-15 Thread Heinrich Apfelmus
Jon Fairbairn wrote: > Heinrich Apfelmus writes: > >> The answer is a resounding "yes" and the main idea is that shuffling a >> list is *essentially the same* as sorting a list; the minor difference >> being that the former chooses a permutation at random while the latter >> chooses a very particu

[Haskell-cafe] Help with Menu item handlers in gtk2hs with glade

2009-02-15 Thread Lakshmi Narasimhan
I designed a basic GUI with Menu bar and menu items in glade. I use the glade bindings in haskell to get the menu item using xmlGetWidget and castToMenuItem function. I set a *onActivateItem* handler for this menuitem. However this is not working. I saw the glade file and it has a signal functi

[Haskell-cafe] Re: permuting a list

2009-02-15 Thread Jon Fairbairn
Heinrich Apfelmus writes: > The answer is a resounding "yes" and the main idea is that shuffling a > list is *essentially the same* as sorting a list; the minor difference > being that the former chooses a permutation at random while the latter > chooses a very particular permutation, namely the

Re: [Haskell-cafe] createProcess shutting file handles

2009-02-15 Thread Duncan Coutts
On Sun, 2009-02-15 at 09:24 +, Neil Mitchell wrote: > Hi > > >> What have I done wrong? Did createProcess close the handle, and is > >> there a way round this? > > > > The docs for runProcess says: > > > >Any Handles passed to runProcess are placed immediately in the > >closed

Re: [Haskell-cafe] Delimited continuations: please comment

2009-02-15 Thread Cristiano Paris
On Sat, Feb 14, 2009 at 2:04 AM, Brandon S. Allbery KF8NH wrote: > > liftIO is defined there, I believe. Many of the monad modules re-export it > with their MonadTrans definitions, but apparently Control.Monad.CC doesn't > so you need to go to the source. Yeah, I knew the answer :D It was sort o

[Haskell-cafe] Feynman on Mathematics and Physics

2009-02-15 Thread Daryoush Mehrtash
Just came across this 6 part video of Feynman lecture on relationship of mathematics and physics. http://www.youtube.com/watch?v=W1jIPzjFU_U&e Enjoy, Daryoush ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinf

[Haskell-cafe] A day with xmonad

2009-02-15 Thread Colin Paul Adams
I have blogged my experience of trying out xmonad with Fedora 10 at http://colina.demon.co.uk/?q=node/534 . -- Colin Adams Preston Lancashire ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] Telnet handshaking

2009-02-15 Thread Martijn van Steenbergen
Hello, Are there any Haskell libraries out there that implement telnet? Bare sockets are a good approximation, but I'm looking for a library that understands the escape sequences specific to telnet. Thanks, Martijn. ___ Haskell-Cafe mailing list Ha

Re: [Haskell-cafe] createProcess shutting file handles

2009-02-15 Thread Neil Mitchell
Hi >> What have I done wrong? Did createProcess close the handle, and is >> there a way round this? > > The docs for runProcess says: > >Any Handles passed to runProcess are placed immediately in the >closed state. > > but the equivalent seems to be missing from the documentation f