On 20/12/11 10:16, Patrick Browne wrote:
Hi,
I am trying to implement a set of 4 modules that blend the action of a
monk moving up a mountain on day 1 and returning down by the same path
on day 2 [1][2]. The code should reflect the fact that there is some
time and place which is common to the
An odd suggestion I know, but take a look at some bibles. The King
James Bible uses the word kind to describe different animals in Genesis 1:
^24 And God said, Let the earth bring forth the living creature after
his kind, cattle, and creeping thing, and beast of the earth after his
kind: and
I would have thought that the compiler, as a matter of optimisation,
could insert a check to see if (==) is comparing an object with itself.
The only way I can see this breaking is with perverse instances of Eq
that would return False for f == f.
Paul.
On 07/20/2011 04:51 AM, Nikhil A.
If you open a file for writing and then exit with output unflushed, then
Haskell does not flush the file for you. In ghci the program seems to
work, but then when you compile it in ghc it mysteriously fails.
I've just been bitten by this, but when I went to the bug tracker I
found
On 11/06/11 14:10, Andrew Coppin wrote:
OK, so suppose you sit down and write a complicated string parser. Now
how do you test that it works correctly?
If you have a function that turns a parse tree back into text again,
you can try verifying that a round-trip is the identity function.
The Haskell Platform web page at http://hackage.haskell.org/platform//
seems to need updating. (Incidentally, that double slash at the end
doesn't look right).
* The next release is promised in Jan 2011.
* The Release Timetable schedules the next release for 5 March 2011.
I just worry that
I installed gtk2hs-buildtools as per the Leksah page, and then tried to
install Leksah itself. I got:
[r...@eiffel download]# cabal install leksah
Resolving dependencies...
cabal: cannot configure leksah-server-0.8.0.8. It requires ghc=6.10.1
6.13
There is no available version of ghc that
On 27/11/10 11:25, Christopher Done wrote:
Interesting. Perhaps Cabal isn't looking at the same GHC version. If
you run cabal install with --version passed to GHC, GHC will just
output the version instead of doing any compiling and the install will
stop. You can see what version Cabal actually
On 27/08/10 23:45, sylvain wrote:
Other sources show growing interest in Haskell (much to the dismay of
our favorite motto).
Would you accept to refer to these other sources?
One interesting one is http://www.itjobswatch.co.uk/jobs/uk/haskell.do
Paul.
Looks interesting. One point: you seem to be using Read and Show
typeclasses for serialisation. I think you would be better off using
Binary, which is much more efficient.
Paul.
On 03/08/10 09:35, Frank Kupke wrote:
Hi,
DSTM is an implementation of a robust distributed Software
On 16/07/10 05:41, Nick Rudnick wrote:
In consequence, an 8-student-project with two B.Sc. theses is raised
as a pilot to examine the possibilities of using Haskell in the
combination small team with limited resources and experience in a
startup setting - we want to find out whether Haskell
On 02/07/10 14:43, Edward Kmett wrote:
Knowledge of Haskell means very different things to different
people. I'd be somewhat leery of blindly hiring someone based on their
ability to answer a couple of pop Haskell quiz questions.
Fair enough, and I should probably have put a smiley in
I'm starting to see job adverts mentioning Haskell as a nice to have,
and even in some cases as a technology to work with.
However right now I'm looking at it from the other side. Suppose
someone wants to hire a Haskell developer or three. How easy is this?
I'd appreciate replies from
On 15/06/10 09:08, Amiruddin Nagri wrote:
I wanted some insight as to how Haskell is going to help me with my
project. Also there has been some concerns because of lazy evaluation
in Haskell and memory leaks associated with it.
On 19/06/10 17:23, Yves Parès wrote:
It helps me understand better, but would you have some simple code
that would do that ?
http://www.cs.chalmers.se/~koen/pubs/jfp99-monad.ps
Paul.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
On 20/06/10 22:03, Paul Johnson wrote:
On 19/06/10 17:23, Yves Parès wrote:
It helps me understand better, but would you have some simple code
that would do that ?
http://www.cs.chalmers.se/~koen/pubs/jfp99-monad.ps
Except that the paper I'm trying to refer to seems to have fallen off
On 19/06/10 10:36, Yves Parès wrote:
Hello,
I saw on the haskell wikibook that coroutines could be implemented by
using continuations :
http://en.wikibooks.org/wiki/Haskell/Continuation_passing_style#Example:_coroutines
(unhappily, the section is empty)
Since I'm actually learning the
On 16/04/10 19:59, Daniel Fischer wrote:
Am Freitag 16 April 2010 20:50:25 schrieb Brian Hulley:
revealed a link to a US Patent (7120900) for the idea of implementing
the Unicode Bidirectional Algorithm (UAX #9
http://www.unicode.org/reports/tr9) in Haskell, making use, as far as I
can
This patent has zero practical impact.
When the patent was written there was no Unicode support, so the
implementation translates the input into lists of integers instead of
lists of characters. Crucially this step was also written into all
three independent claims (which are the only bit of
On 13/03/10 10:06, Juraj Hercek wrote:
Hello,
I'm thinking about using Data.Binary to parse binary stream of data.
Binary data stream consists of messages which can have one or more
(sometimes couple of hundreds) sub-messages. The stream is spitting
out data slowly.
I would like to parse
Thats because you can't put a where in a then clause. Move the
where stuff to the end of the function.
On 09/03/10 19:04, boblettoj wrote:
Hi, i am getting an error when trying to compile this part of my program, its
my first time using haskell and as lovely as it is it didn't give me very
On 19/02/10 22:31, Don Stewart wrote:
paul:
I'd like to use this kind of graph at work as evidence that Haskell is
on a growth trajectory.
You might be more interested in data from Hackage:
http://www.galois.com/blog/2009/03/23/one-million-haskell-downloads/
runched when we
If you go to
http://www.ohloh.net/languages/compare?l0=haskellmeasure=projects and
look at the number (not percentage) of Haskell projects you see it rise
exponentially until the start of 2008 and then suddenly drop away. Does
anyone know what happened? Assuming this is just an artefact
On 18/01/10 20:33, Paul Johnson wrote:
I'm going nuts looking at this. Can anyone see what I'm doing wrong?
I found the problem eventually. Its a scoping problem with rt1 in the
(.) function when composeSP gets called recursively.
___
Haskell
Hi,
I'm trying to write an arrow for a real-time stream processor. I'm
basing it on the SP type in Hughes paper on Generalising Monads to
Arrows (http://www.cs.chalmers.se/~rjmh/Papers/arrows.pdf) section 6.
I've extended this with a notion of time by making each step a function
of time.
On 15/12/09 21:19, Anton van Straaten wrote:
Without that advocacy, this client would have used Java by default.
As it was, the first of those two systems was developed in parallel
with a Java version, and we used the two versions to verify each
other's results. For the second system, a
On 10/12/09 12:07, Magnus Therning wrote:
As I understand it it all started with laziness. I don't know if
laziness is impossible without purity, but talks and papers tend to
say something like laziness has kept Haskell pure.
This is true, but laziness has its own advantages. Suppose I have
On 04/12/09 11:51, Patrick Caldon wrote:
I'm looking for the right concurrency library/semantics for what
should be a reasonably simple problem.
I have a little simulator:
runWorldSim :: MTGen - SimState - IO SimState
it takes about a second to run on a PC. It's functional except it
On 02/12/09 01:55, Michael Mossey wrote:
I have a quite messy problem which is describable as a big state
machine, at least in the way I think of it. An input event can
trigger a cascade of changes to the state. Channel numbers must be
assigned and tracked, table numbers as well, decisions
On 18/11/09 11:54, Philippos Apolinarius wrote:
I wonder whether the Haskell community tryed to reproduce the study
Lisp as an alternative to Java, by Ron Garret / Erann Gat.
Sort of. See http://www.haskell.org/haskellwiki/Phone_number
Paul.
This question on StackOverflow asked about how to find the largest 100
items in a very long list:
http://stackoverflow.com/questions/1602998/fastest-way-to-obtain-the-largest-x-numbers-from-a-very-large-unsorted-list/1603198#1603198
I replied that you could do it with something like this (but
On 22/10/09 15:31, Paul Johnson wrote:
takeLargest k = take k . sort
Because sort is lazily evaluated this only does enough sorting to
find the first k elements. I guess the complexity is something like
O(n*k*log(k)).
Correction: O(n*log(k
What about Lambdabot?
On 10/10/09 20:22, Miguel Mitrofanov wrote:
Just a note: Haskell and 'tan' in one sentence, combined with some
girlish flavour, makes me think about Audrey TANg.
On 10 Oct 2009, at 23:02, Svein Ove Aas wrote:
I say competition, but.. at the moment I'm only aware of a
On 08/10/09 04:57, David Menendez wrote:
On Wed, Oct 7, 2009 at 8:29 PM, Michael Mosseym...@alumni.caltech.edu wrote:
In Test.QuickCheck, the type of 'generate' is
generate :: Int - StdGen - Gen a - a
I can't find docs that explain what the Int does. Some docs are here:
Judging
I can't help with the title, but you might show how Haskell can help
avoid the subtle bugs that create erroneous results. Start with the
dimensional library (http://hackage.haskell.org/package/dimensional).
Paul.
___
Haskell-Cafe mailing list
One alternative approach is to use QuickCheck to test many trees and
look for counter-examples. You can also use SmallCheck to do an
exhaustive check up to a chosen size of tree.
To do this with QuickCheck you would write a function such as
prop_mirror :: Node a - Bool
prop_mirror x =
This is a bit beyond my normal level of expertise, but if I understand
it correctly the type checker is normally limited to type functions that
are primitive recursive
(http://en.wikipedia.org/wiki/Primitive_recursive_function). This means
that they are guaranteed to terminate, but on the
Lyle Kopnicky wrote:
I think it's a combination of 1) the expressiveness measure is too
simplistic, measuring number of lines alone, or counting comments, and
2) the problem set is skewed toward number-crunching, which is not
(say) Prolog's strong suit.
Also there is a strong tendency to
michael rice wrote:
I was just looking at my UML (Unified Modeling Language) User Guide
and discovered this:
The number of object-oriented methods increased from fewer than 10 to
more than 50 during the period between 1989 and 1994. pg. xviii,
Booch, Rumbaugh, Jacobson, 1999
Is there a
Sounds like you need regular expressions applied to the string
representation, although the sequence of increasing numbers is not
something any of the standard regexp packages do. So you will have to
roll your own.
Alternatively you could use one of the parsing libraries to parse the
string
Frank Rosemeier wrote:
Dear Haskellers,
I would like to implement a board game for a single player in Haskell.
The pieces may be moved one step in any direction if there is no piece
next to it,
and the goal is to rearrange the pieces to their home positions.
The Haskell program should find
On Mar 31, 2009, at 12:16 AM, Vlad Dogaru wrote:
More specifically, I would be interested in the degree the Haskell
community uses XML Schema, and if you were tempted to use it if we had
an implementation. To further expand the question, how useful do you
consider each of these components:
* a
Ed McCaffrey wrote:
Other investors I have spoken with want me to contact them again when
it is further developed;
That means no. See
http://blog.guykawasaki.com/2006/01/the_top_ten_lie.html
Paul.
___
Haskell-Cafe mailing list
Derek Gladding wrote:
Please forgive me if I'm still mentally contaminated by the OO way of
seeing (and discussing) the universe, but I'm trying to figure out how
to inherit an interface from a multi-parameter type class.
[...]
but this isn't allowed (kind mismatch).
Kinds are a meta-type
I want to write a parser for a Haskell-like type language. Amongst
other things this means having a symbol table of top-level
declarations. So for instance I want to be able to write in my type
language:
type Foo = Bar Int
data Bar a = Bar String a
I can come up with a parser that
Oops. The last code sample should have been
parseDeclarations :: Parser [Declaration]
parseDeclarations = mdo
decls - many ParseDeclaration symbols
let symbols = makeSymbolTable decls
return decls
___
Haskell-Cafe mailing list
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
Peter Verswyvelen wrote:
Consider the following code
stamp v x = do
t - getCurrentTime
putMVar v (x,t)
Is it possible - with GHC - that a thread switch happens after the t
- getCurrentTime and the putMVar v (x,t)?
If so, how would it be possible to make sure that the operation of
Paul Johnson wrote:
A call has gone out
http://www.haskell.org/pipermail/haskell-cafe/2008-December/051836.html
for a new logo for Haskell. Candidates (including a couple
http://www.haskell.org/haskellwiki/Image:Haskell-logo-revolution.png
of mine
http://www.haskell.org/sitewiki/images/f/fd
Bulat Ziganshin wrote:
Hello haskell-cafe,
pure functional denotation for crisis:
(_|_)
See also:
http://www.haskell.org/haskellwiki/Humor/Enron
http://paulspontifications.blogspot.com/2008/09/why-banks-collapsed-and-how-paper-on.html
Paul.
Tom Hawkins wrote:
Such a database would help me counter by boss's
argument that it's impossible to find and hire Haskell programmers.
There was a thread last week where someone asked who would be interested
in a hypothetical Haskell job. He got about 20 positive responses.
This agrees
Warren Harris wrote:
I am seeking suggestions from the haskell cafe for teaching functional
programming concepts to colleagues at work.
I'd suggest starting with a couple of hours of Why Haskell talk to
sell them on the concepts, followed by something like the the study
group you mentioned
Paulo Tanimoto wrote:
Another idea: something in the form of an Ouroboros. Is that already
taken for a programming language?
http://en.wikipedia.org/wiki/Ouroboros
Something like this?
http://www.haskell.org/sitewiki/images/f/fd/Ouroborous-oval.png
Paul
A call
has gone out for a new logo for Haskell. Candidates (including a couple
of mine)
are accumulating here.
There has also been a long thread on the Haskell Cafe mailing list.
I've lived through a couple of corporate rebranding exercises in my
time, and I've read about some others. They
Hugo Pacheco wrote:
http://www.aegisub.net/2008/12/if-programming-languages-were-religions.html
What does it mean, *If* Programming Languages were religions?
Paul.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
Andrew Coppin wrote:
So I want some sort of sequencing primitives.
Sequencing generally suggests a monad. something = do { action1; delay
10; action2}
I had a go at writing what I thought the interface might look like.
(Fortunately, I made no attempt to *implement* it - otherwise I would
I've just been looking at the Data.Map function fromListWith.
According to the docs, it has the type:
* fromListWith* :: Ord
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data-Ord.html#t%3AOrd
k = (a - a - a) - [(k, a)] - Map
Alexander Dunlap wrote:
On Sat, Dec 6, 2008 at 12:22 PM, Paul Johnson [EMAIL PROTECTED] wrote:
I've just been looking at the Data.Map function fromListWith. According
to the docs, it has the type:
* fromListWith* :: Ord
http://www.haskell.org/ghc/docs/latest/html/libraries/base/Data
Hi,
I'm trying to set up some operators for applicative versions of prelude
types. For instance:
-- | Applicative Equality.
class (Eq a) = AppEq f a where
(.==.), (./=.) :: f a - f a - f Bool
instance (Applicative f, Eq a) = AppEq f a where
(.==.) = liftA2 (==)
(./=.) = liftA2 (/=)
Paul Johnson wrote:
Hi,
I'm trying to set up some operators for applicative versions of
prelude types.
I forgot to mention, I'm using {-# OPTIONS_GHC
-fallow-undecidable-instances -XFlexibleInstances
-XMultiParamTypeClasses #-}
Paul
Friedrich wrote:
Ok to be more concrete is the laziness hidden here?
check_line line sum count =
let match = matchRegex regexp line
in case match of
Just strs - (sum + read (head strs) :: Integer, count + 1)
Nothing - (sum, count)
Probably.
Friedrich wrote:
Paul Johnson [EMAIL PROTECTED] writes:
[...] Because file reading is lazy,
each line is only read when it is to be processed, and then gets
reaped by the garbage collector. So it all runs in constant memory.
Would you mind to elaborate a bit about it. What's so
Friedrich wrote:
I've written just a few programs in Haskell one in a comparison for a
task I had nearly daily.
The first thing I notice is that this is clearly a direct translation
from something like Perl. Thats understandable, but I'd suggest
rewriting it with something like this
Derek Elkins wrote:
All you need is a T-shirt: http://www.cafepress.com/skicalc
Or http://www.cafepress.com/l_revolution
Paul.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
Andrew Coppin wrote:
Oh, no. The entire bar is 2 Kg, I wasn't actually planning to eat the
whole thing! o_O My god, my pancreas would explode or something...
My Dad once ate two bars of dark cooking chocolate. He said he got some
odd visual distortions; flickering auras around things, and
Pieter Laeremans wrote:
Hello,
I've written a cgi script in haskell, it crashes sometimes with the
error message Prelude . tail : empty list
Yup, been there, done that.
First, look for all the uses of tail in your program and think hard
about all of them. Wrap them in assert or trace
Daryoush Mehrtash wrote:
The MaybeT transformer is defined as:
newtype MaybeT m a = MaybeT {runMaybeT :: m (Maybe
http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#t:Maybe
a)}
instance Functor http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#t:Functor m
minh thu wrote:
Do you suggest I use
data Thing = Thing | None
and IORef Thing instead of
data Thing = Thing
and Maybe (IORef Thing) ?
I'm writing a data structure that can hold Things (and that can be mutated) or
nothing (there is a hole in the wrapping data).
I'd have thought you
This is a strange question, I know, but is there anyone working in any
of the above companies on this mailing list?
Everyone will no doubt be wondering what they have in common. I'm
afraid I can't discuss that.
Paul.
___
Haskell-Cafe mailing list
Paul Johnson wrote:
This is a strange question, I know, but is there anyone working in any
of the above companies on this mailing list?
Everyone will no doubt be wondering what they have in common. I'm
afraid I can't discuss that.
I will say that this is not a job search, and I'm
Ryan Ingram wrote:
I think you can use the duality of Writer/Reader to help you here; you
have the law that, for suitable dual computations r and w,
run_reader r (run_writer (w x)) == x
Then you can build up a list of rules specifying which computations
are dual; read64 is dual to write64, for
I'm trying to understand how to use GADT types to simulate dependent
types. I'm trying to write a version of list that uses Peano numbers
in the types to keep track of how many elements are in the list. Like this:
{-# OPTIONS -fglasgow-exts -fallow-undecidable-instances #-}
module Plist
Daniel Fischer wrote:
My Oleg rating isn't high either, and certainly you can do it more elegant,
but
class Concat l1 l2 l3 | l1 l2 - l3, l1 l3 - l2 where
pConcat :: l1 a - l2 a - l3 a
instance Concat (Plist Zero) (Plist n) (Plist n) where
pConcat _ ys = ys
instance Concat (Plist
Achim Schneider wrote:
There won't ever be a space leak without a time leak nor a time leak
without a space leak. I'd just call it a leak.
Actually I think you can have a space leak without a time leak. For
instance if every time around the main loop I cons data onto a linked
list that
We've had a big debate over
mean xs = foldl' (+) 0 xs / fromIntegral (length xs)
For anyone who didn't follow it, the problem is that mean needs to
traverse its argument twice, so the entire list has to be held in
memory. So if xs = [1..10] then mean xs uses all your
memory, but
Jeff Polakow wrote:
[...] This can be easily fixed by defining a suitable strict sum:
sum' = foldl' (+) 0
and now sum' has constant space. We could try to redefine mean using
sum':
mean1 xs = sum' xs / fromIntegral (length xs)
but this still gobbles up memory. The reason is that xs
PR Stanley wrote:
Hi
What is the difference between
data T0 f a = MkT0 a
instance Eq (T0 f a) where ...
and
data T0 f a = MkT0 a
instance Eq a = Eq (T0 f a) where ...
The second one says that TO f a is only an instance of Eq if a is,
while the first says that TO f a
I've just uploaded version 0.1.0 of a decimal arithmetic package to
Hackage. Decimal numbers are stored as an Integral mantissa and a Word8
exponent, where the number stored is mantissa * 10^(-exponent). In
other words the exponent is the number of decimal places stored. There
are also
iliali16 wrote:
Hi guys I have to build the wumpus world problem. I didn't start yet since
this is the first time in my life I have to do something like that and I
feel not confident in starting it. So I have basic idea of what prolog and
haskell can do and I know a bit of Java. I am wandering
Shaun Cutts wrote:
I note that there is a unit testing framework for Haskell, but I don't
see any doctest module. Might this be a good project?
I once looked at doing this, but I didn't get very far.
Haddock is important here because you want to include the tests as part
of the documentation.
Dean Herington wrote:
At 6:41 PM -0700 3/21/08, Adam Langley wrote:
Also
getter - fmap (amqpGetTable !) getWord8
getter
is just
fmap (amqpGetTable !) getWord8
I don't think so. Aren't there two gettings: the first to get the
type byte and the second to get the item?
Yes.
I'm trying to implement the AMQP framing layer. This is the bottom
layer of the protocol that packs and unpacks data in lazy ByteStrings.
I'm using the Binary package with its Get and Put monads to do the
unpacking, and that works well. But I've run into a problem and I can't
find an
Alan Carter wrote:
I've written up some reflections on my newbie experience together with
both versions, which might be helpful to people interested in
popularizing Haskell, at:
http://the-programmers-stone.com/2008/03/04/a-first-haskell-experience/
Thank you for writing this.
On the lack
I was looking through my old copy of The Devil's DP Dictionary by Stan
Kelly-Bootle, and came across the entry for Stepwise Refinement. I
thought I've seen this before: this is a parody of Darcs patch
theory. It included the Null patch, chains of patches, inverse
patches, and pseudo-inverse
Miguel Mitrofanov wrote:
Does it start with Any sequence of KLUDGES, not necessarily distinct
or finite...? If so, it can be found in The Computer
Contradictionary, by the same author, and probably illegal copy of
the last book can be found in the net somewhere.
Indeed. In fact I'm not even
I'm working on an implementation of the framing layer for AMQP
(www.amqp.org). I almost had 0.9 finished when I found they had
released the spec for 0.10, so I have to redo quite a lot of work.
Amongst the new features of 0.10 are wire formats for floating point.
These are the 4 and 8 byte
Peter Verswyvelen wrote:
PS: This job offer was already placed in the Haskell Café a while ago,
but I was advised there to place it in the main Haskell list. I hope
this is not considered as spam.
I certainly don't see it as spam. One day there will be a dozen jobs
for Haskell programmers
Berlin Brown wrote:
I started a AMQP library; there really isn't a lot there but at least
I was able to connect to the server.
Arrgh: I was hoping I would be the first to announce this. I've been
working on one (on and off) for a few months now. I've got most of the
translation from XML
Don Stewart wrote:
berlin.brown:
I started a AMQP library; there really isn't a lot there but at least
I was able to connect to the server. Here is the code and hopefully
someone else can continue with the project.
Thanks!
Would you like this packaged up for hackage.haskell.org, so
Evan Laforge wrote:
Java's just wordy like that. In python you'd say max(foos, key=lambda
x: x.update_time).
While this is true, I was also thinking of the typical audience SPJ
specified: senior technical people and managers. Most of these people
have heard of Python and Ruby, but see
Tim Chevalier wrote:
On 1/26/08, Paul Johnson [EMAIL PROTECTED] wrote:
* Say computers are cheap but programmers are expensive whenever
explaining a correctness or productivity feature.
This is true only if talking to people in high-income nations.
Even in low-income
Simon Peyton-Jones wrote:
1. Small examples of actual code. The goal here is (a) to convey a visceral idea of what functional programming *is*, rather than just assume the audience knows (they don't), and (b) to convey an idea of why it might be good.
Here is one I came across in the last few
Ronald Guida wrote:
Hi,
I'm interested in learning how to program games. Since I have to start
somewhere, I decided to write a simple Hangman game. I'm wondering if
anyone can look at my code and give me some feedback.
Nicely written. The design reads very much like a straight translation
I was recently sent a patch for my Ranged Sets library which exported
all the QuickCheck properties. I'd left them unexported on the grounds
that they clutter up the documentation (although simplified versions are
included in the documentation) and you can easily run them with the
standard
Michael Roth wrote:
Yes, I have done: push, pop, top, nop, count, clear, isolate and binop.
All pretty easy, once I understand that Stack a b thing.
Now you are ready to write your monad tutorial. This is a standard rite
of passage (or should that be write a passage) for new Haskell
Miguel Mitrofanov wrote:
Yes. It's simply impossible. The Stack data type can't be turned into
a monad.
Why not? Surely this is just a variation on the theme of a state monad?
Paul.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
Ben Challenor wrote:
Hi
I'm learning Haskell through writing a compiler. I'm seeing huge
memory use in a function which converts the dataflow graph to the form
required by Data.Graph. [...]
I assume the allocation is being garbage-collected pretty quickly,
because a) 6,616,297,296 bytes is
Tim Docker wrote:
I found it worthwhile to try and visualise what's going on here. Let's
say I have 4 calculations that I want to run in parallel. The first
doesn't need a request; the second needs to make a single request
(A1); the third needs to make two requests where the second (B2)
depends
Cristian Baboi wrote:
Let me show you an example to prove it.
This reminds me of arguments in the late 80s and early 90s that C could
do OO programming via function pointers, so there was no need for OO
languages.
Paul.
___
Haskell-Cafe mailing
Andrew Coppin wrote:
Program with no particular optimisations: 0.35 seconds.
Program with stream fusion [and GHC HEAD]: 0.25 seconds.
Program with stream fusion and ByteString: 0.05 seconds.
Surely you'd have to work pretty hard to get that kind of speed even
in C. ;-)
...erm, actually no.
1 - 100 of 167 matches
Mail list logo