Hi,
Some years ago, I set up the biohaskell.org domain with mailing list,
wiki, etc, in order to collect bioinformatics tools, utilities, and
libraries written in our favorite languages.
Time has moved on, and I with it, and I am no longer doing (much)
bioinformatics, and (sadly) also less Haske
"Skeptic ." writes:
> I finally have an opportunity to learn Haskell (I'm a day-to-day Java
> programmer, but I'm also at ease with Scheme), parsing a huge (i.e. up
> to 50 go) binary file. The encoding is very stable, but it's not a
> flat struct array (i.e. it uses flags).
I use binary <0.5 (
Ivan Lazar Miljenovic writes:
>> Did someone forget to renew www.haskell.org? Who does this?
I'm not sure how we can find out who was previously registered.
>> Also plain http://haskell.org/ used to work, but doesn't any more.
> Both work fine here (just checked)...
They both point to the sa
A long, long time ago, on a mailing list far away, Don Stewart
wrote:
> Here are the notes transcribed from the Future of Haskell BoF held
> after the Haskell Symposium last week.
> * Need to encourage special interest groups (SIGs) to form around
>particular domain areas in the libraries
Ivan Lazar Miljenovic writes:
>> A good email client (like Gmail), deals with this without a problem by
>> collapsing the two emails into one.
This is correct, of course. I can fix it, if I get annoyed enough.
Unfortunately, evidence seems to indicate that the annoyed of us tend to
fix it by un
Lee Duhem writes:
>> This was intended to avoid duplication, as I assume most people on
>> haskell-cafe also read haskell. But maybe this is not true...
> I think so, because for quite a while, I've been a reader of
> Haskell-Cafe, but not Haskell.
> Anyway, I noticed you have post it to Haskell
"Angelos Sphyris" writes:
> Surely, I can't be the only person to suspect an April Fool's Day joke
Well, since nobody seems to bite anyway, I guess I might as well 'fess
up.
As we rely on Simon P J and others like him not only to provide us
with the theoretical foundations, but also with the
sylvain writes:
> Le samedi 21 mars 2009 à 09:58 -0700, Don Stewart a écrit :
>> Oh boy. Compile with optimizations on please! ghc -O2 et al.
> I had done that, actually, before even my first post, and knew that it
> changes little to the picture, at least on my system.
I think Bulat was right
"Krasimir Angelov" <[EMAIL PROTECTED]> writes:
> Does some one have made performance tests on the different XML libraries for
> Haskell? I have a 20MB xml file that I want to read. I remember from my
> earlier
> experiments (years ago) that all libraries were too slow and were consuming
> too
>
Friedrich <[EMAIL PROTECTED]> writes:
> Even the ruby solution need just
> check_downloads/check_downloads.rb . 1,25s user 0,06s system 99% cpu
> 1,322 total
[...]
> but the haskell solution:
> ./chk_dwlds 17,71s user 0,11s system 99% cpu 17,836 total
I'm very surprised to see this. Did y
Benjamin L.Russell <[EMAIL PROTECTED]> writes:
> In that case, how about the following, more detailed charter:
> "Beginner-level discussion about primarily non-research-oriented
> topics
This part is good. Friendly and inviting - nothing scary here.
> serving the needs of non-computer-science
"Peter Verswyvelen" <[EMAIL PROTECTED]> writes:
> Well, if somebody can't spell "beginners" correctly, I highly doubt they
> will get "alpha" right... Certainly if they drive an Alfa Romeo car ;)
For the beginning Haskell programmer owning an Italian sports
car, I cannot resist suggesting "[EMAIL
Simon Marlow <[EMAIL PROTECTED]> writes:
> My main concern here is that the remit for the new list is not clear
> enough. I can see a potential need for two lists:
>
> * a list for discussion related to teaching Haskell;
>
> * a list devoted to those learning Haskell, with a less research-
>
Jinping Zhang <[EMAIL PROTECTED]> writes:
> HI,can anybody help me with the following garbage collection problem ?
It's probably not a problem with garbage collecting as such, but
rather that you don't have any. In other words, your program is
retaining too much data. Often, this is caused by t
Bjorn Lisper <[EMAIL PROTECTED]> writes:
> Wait, Jerzy. Haskell implementations do not have to be lazy as long as they
> preserve the more abstract semantics. Optimistic evaluation has been
> considered, for instance by Robert Ennals.
I'm not sure if the GC hack proposed by Wadler¹ that lets the
Simon Marlow <[EMAIL PROTECTED]> writes:
>> +1 to renaming the new base, and have 'base' be a compatibility
>> package incorporating 'containers', 'array', etc
> There's currently no (easy) way to make a package that just re-exports
> the contents of other packages.
Presumably the hard way would
Udo Stenzel <[EMAIL PROTECTED]> writes:
[incompatibilities between recent libraries/cabal/ghc]
I'm installing a GHC-6.8 snapshot, and compiling a bunch of libraries
I need in the process (HTTP, HXT, and binary). No show-stoppers, but
a lot of rewriting of the dependencies. At least ghc will t
On Sun, 2007-09-23 at 23:24 +0200, Tomas Caithaml wrote:
> I came up with:
Just take the computer science courses that the fewest of your fellow
students see any point to.
More seriously - at my alma mater, the math-oriented computer science
courses would be a better fit. My last one was on uni
On Wed, 2007-09-05 at 13:02 +1000, Donald Bruce Stewart wrote:
> The xmonad dev team is pleased to announce the 0.3 release of xmonad.
I just wanted to congratulate the team, and say that xmonad is, along
with darcs, my favorite "mainstream" Haskell program. I used to spend
days experimenting w
Frederik Eaton <[EMAIL PROTECTED]> writes:
>> It looks nice, but don't you think the -package-base flag ought to
>> take both the package name *and* the mountpoint?
> My intention was that -package-base specifies a base for the package
> specified in the preceding -package flag [...]
> In other w
Robby Findler <[EMAIL PROTECTED]> writes:
> Just out of curiosity, did you try "wc -l"?
>> import qualified Data.ByteString.Lazy.Char8 as L
>> main = L.getContents >>= print . L.count '\n'
..or
import Data.ByteString (hGetLines)
main = hGetLines IO.stdin >>= print . List.length
?
-k
Wolfgang Jeltsch <[EMAIL PROTECTED]> writes:
>>> Thinking about the subject matter is
>>> hard enough, thinking about creating licensing pitfalls is best left to
>>> lawyers and other parasi^W specialists.
The problem is that lawyers are thinking about pitfalls for you to
fall into. Discussing l
Simon Marlow <[EMAIL PROTECTED]> writes:
>> Thus defaulting the FDL for all wiki content, including code, is a
>> very bad idea.
> I agree - can we please use BSD or public domain?
Another option is the Open Publication License, which requires
acknowledgement (but little else). Anyway, I think
"Simon Peyton-Jones" <[EMAIL PROTECTED]> writes:
> * Gour suggested using a Content Management System (e.g. Drupal
> http://drupal.org/) for haskell.org's front page.
I'm not familiar with Drupal, but at least EZ publish allows users to
convert pages to PDF - could be quite useful for documentati
Johannes Waldmann <[EMAIL PROTECTED]> writes:
> Again, the concrete syntax problem is whether to hide the argument.
> Perhaps data Foo = Foo { foo :: Int, bar :: Int ; bar = 2 * foo self }
> with a reserved word "self" is better. - Are there semantic problems?
Can't you solve this by writing a f
John Lask wrote:
I would like to sound out the Haskell community on what the feeling
are most desirable to improve the "commerciality" (i.e. its general
use) of ghc and Haskell in general (as distinct from feature set)
I think more standardization on an extended feature set would be nice.
I
Wolfgang Jeltsch wrote:
The potential of newsgroup was also mentioned - creating of
compl.lang.haskell, but I won't comment of it considering that the
newsgroup cannot be one & all solution, and, otoh, does not, imho, provide
any substantial advantage over the other three forms (we already have
Alberto Fuentes Rodriguez wrote:
isRepeated :: Eq a => [a] -> Bool
isRepeated [] = False
isRepeated (p:r) = (any (\x -> x == p) r) || isRepeated r
Two comments:
You can write "any (==p) r", using a partial application of the equality
predicate. Reads better IMHO.
This is O(n²), sorting and
Rene de Visser wrote:
I want to write a multi-dimensional unboxed arrary of Int32 to a file.
(And also read it back later).
hGetArray/hPutArray?
-k
___
Haskell mailing list
Haskell@haskell.org
http://www.haskell.org/mailman/listinfo/haskell
--
Subject:Bug in Data.IntSet?
Date: Thu, 27 Oct 2005 15:25:30 +0200
From: Ketil Malde <[EMAIL PROTECTED]>
To: glasgow-haskell-users
AFAICT, there is a bug in Data.IntSet.split
Here's an excerpt from GHCi:
*Main> let m=482 in Data.IntSet.split (16*m) $ Data.IntSe
Creighton Hogg <[EMAIL PROTECTED]> writes:
> So I looked to see if there were any standard functions for
> taking an input line and turning it into a list, and I
> couldn't find any. How would one do this in Haskell? I
> just want to parse the line into a list of strings, and
> from there re
"Scherrer, Chad" <[EMAIL PROTECTED]> writes:
> I'm trying to understand the "entries" column. I thought this was the
> number of times a given function is called. But "main" is nonrecursive,
I thought so, too. My guess would be that your program doesn't do
quite what you think it does, or that o
Bulat Ziganshin <[EMAIL PROTECTED]> writes:
> I can quote someone from this list: "if haskell compiler allow my
> program to be compiled then I know that there is no more errors in
> it".
I wish quotes like this weren't bandied about without mentioning that
they almost entirely, but not quite, tr
mt <[EMAIL PROTECTED]> writes:
> http://paulgraham.com/lispfaq1.html
> [Most hackers I know have been disappointed by the ML family. Languages with
> static typing would be more suitable if programs were something you thought
> of in advance, and then merely translated into code. But
Alex Edelsburg <[EMAIL PROTECTED]> writes:
> I removed both import statements from the code and tried to run
> again. This time HUGS generated the following error.
> ERROR "Animation.hs":57 - Undefined variable "word32ToInt"
...which is, as pointed out previously, deprecated in favor of
"fromInte
Jim Apple <[EMAIL PROTECTED]> writes:
> robert dockins wrote:
>>> Why remove a feature from a product? Why not, instead, just choose
>>> to not use it?
>> Because the feature complicates the product, increases maintainance
>> costs, and keeps the maintainers from working on other things people
>
Benjamin Franksen <[EMAIL PROTECTED]> writes:
>> It seems to me that the layout conventions work pretty well. I do not
>> see much code where it is not used, so generally people must like it.
Works for me. It helps *a lot* to have a sensible editor that knows
where to position things of course.
Mads Lindstrøm <[EMAIL PROTECTED]> writes:
> But we do not have to leave out ASCII based editors - atleast to begin
> with. You can be showing functions like sqrt using real math symbol and
> at the same time store your documents as ordinary Haskell sources, which
> can be read by any editor. This
Ketil Malde <[EMAIL PROTECTED]> writes:
> I have some problems getting profiling to work with a ghc-6.4 that I
> compiled from source. Everything seems to work all right, but the
> output doesn't contain any times
[...]
> (ghc 6.4 compiled from source with ghc 6.2.
Hi,
I have some problems getting profiling to work with a ghc-6.4 that I
compiled from source. Everything seems to work all right, but the
output doesn't contain any times; in time profiling (+RTS -p) times are
all zeros, with heap profiling, I never get any 'samples' output, just
an empty one.
Ben Rudiak-Gould <[EMAIL PROTECTED]> writes:
> How is this different from any other environmental change, such as a change
> in the program arguments?
Isn't this really the old (or fairly recent) discussion of "top level
things with identity"? Should one be able to do something like
args
Ketil Malde <[EMAIL PROTECTED]> writes:
> Andrew Cooke's haskell.sty file.
By popular demand (two interested, and nobody asking me not to :-) I
put my hacked version of haskell.sty out here:
http://www.ii.uib.no/~ketil/tex/
Also available as a darcs repository. I'm a te
Hi,
For those of us (I know at least one more) who like to write
LaTeX-based literate programs, I've recently been hacking a bit on
Andrew Cooke's haskell.sty file. If anybody else is interested in a
revised version, or has modifications of their own, please drop me a
mail. (I can also make it a
Ketil Malde <[EMAIL PROTECTED]> writes:
> Did you perhaps mean:
>
> g :: a -> a = \x -> x
>
> which has type () -> () ?
Or maybe the difference between:
g :: Num a => a -> a
g = \x -> 1
(which gives the specified type) and
g' :
Paul Govereau <[EMAIL PROTECTED]> writes:
> This is a great example, thanks for posting it. However, I feel like
> the real problem in this example is the lexically-scoped type
> variables declared with your function f. I am always surprised by the
> effects that lexically-scoped type variables ca
Lest it all be explanation by example, the story basically goes like
this:
Binary functions can be used in infix style by surrounding the
function name by backticks (plus x y <=> x `plus` y)
Binary operators can be used in prefix style by enclosing it in
parentheses ( 4 + 3 <=> (+) 4 3 )
And
Glynn Clements <[EMAIL PROTECTED]> writes:
>> 2) display result of the analysis (pie charts, histograms, plots)
> If you don't need to interact with the display, the simplest solution
> is to generate graphics files. Personally, I would use PostScript
I would output to Gnuplot...
> as I'm reas
"A.J. Bonnema" <[EMAIL PROTECTED]> writes:
> Actually, I asked kdevelop to run in an external terminal. Also, if I
> run the command "./prog" (where prog is the name), the program behaves
> the same. So, ghc should not assume anything else than having input
> from standard input
Hmm...did you
"A.J. Bonnema" <[EMAIL PROTECTED]> writes:
> Why doesn't kdevelop generate code, that executes the statements in
> order? Or should I be looking at ghc? Or is it an option I am missing?
GHCi behaves like Hugs. My guess would be that kdevelop attaches
pipes for standard input and output, and GHC
Oops. Lest anybody should copy it blindly:
mkpgm :: Array (Int,Int) Int -> String
mkpgm cm = header ++ "\n" ++ image
where header = unwords ["P2",show width,show heigth,show maxval]
image = unlines $ map show $ elems cm
- (width,heigth) = snd $ bound
Graham Klyne <[EMAIL PROTECTED]> writes:
>> I want to use the memo function for implementing a dynamic
>> programming algorithm in Haskell.
> - rather than using a function to perform a calculation, use some kind
> of indexed data structure to hold the results, initialized with
> appropriate exp
Stephan Herhut <[EMAIL PROTECTED]> writes:
> module B(bar) where
> instance Foo Integer where
> module C(tango)
> instance Foo Integer where
> import B(bar)
> import C(tango)
> But now, ghc complains about two instances of Foo Integer, although
> there should be none in the namespace main.
I s
MR K P SCHUPKE <[EMAIL PROTECTED]> writes:
>>Thank you for the programming practice recomendation,
> Sorry if it seemed like that...
Huh - I thought that was sincere; certainly I am happy to learn about
sensible (or not) practices that others find useful.
> but I do feel that 'commercial quali
Fergus Henderson <[EMAIL PROTECTED]> writes:
> Seeing as Haskell is apparently such a popular language these days,
> I don't suppose a working debugger would be too much to ask for, would it?
Hah. You're not supposed to debug, just stare at the code until
you become enlightened (why did you thin
"Tim Docker" <[EMAIL PROTECTED]> writes:
> Of course... that was my second alternative error strategy. I'm
> interest in how/when people decide when to throw exceptions versus
> when to thread errors using monads, given that changing code from
> one to the other could be quite a big deal.
I gener
"Serge D. Mechveliani" <[EMAIL PROTECTED]> writes:
> Alexander is right.
>
> Also as Integer has more sense than Int,
> I would suggest for the future standard Haskell library to have
> Integer as default. For example:
> length :: [a] -> Integer
>
"Stenio" <[EMAIL PROTECTED]> writes:
> It is strange because fromInt works in the hugs prompt But when I
> use it in my haskell script it doesn´t work.
It is tempting to say that it is because you top-post HTML, but
I'll be good and refrain.
> average :: Int -> Float
> average n = fromInt ( sum
"Stenio" <[EMAIL PROTECTED]> writes:
> I was using Hugs November 2002 and the function fromInt works fine,
> but in the version November 2003 the same function doesn´t work.
I'm too lazy to check the standard, so I'll just assume Hugs was
wrong. I think the solution is to use "fromIntegral" inst
rui yang <[EMAIL PROTECTED]> writes:
> I'm a new comer in functional programming,I have defined some
> functions in Haskell and I want to know how much CPU time each
> function need and compare the efficiency of these functions. The
> question is how should I test the CPU time of my function? it s
Peter Strand <[EMAIL PROTECTED]> writes:
> That is, a function is looked up in the namespaces of its arguments as
> well as in the normal places. So "add fm k v" where fm :: FiniteMap,
> x :: Int, v :: String would look for "add" in the modules where
> FiniteMap, Int and String was defined.
I sup
[EMAIL PROTECTED] writes:
> addToFM :: Ord key => FiniteMap key elt -> key -> elt -> FiniteMap key
> elt
> addToSet :: Ord a => Set a -> a -> Set a
> So, how can you come up with a type class which provides a
> polymorphic 'add' function, considering you don't even know how many
> parameters eac
Hi,
Since I discovered that my program spent most of its time reading and
writing files, I had a go at transforming it from using readFile to
using array IO.
Since my file consists of lines of length 18, I tried writing a
similar function to readFile, to return a lazy list of lines as
arrays, in
"S. Alexander Jacobson" <[EMAIL PROTECTED]> writes:
> However, if my application reads many more times than it writes,
> then perhaps I can get a substantial performance boost by increasing
> the branch factor on the tree. For example, if each node was an
> array of 256 elements, reads would be O
Koen Claessen <[EMAIL PROTECTED]> writes:
> And instead of:
>
> mapSet, emptySet, ...
> We have:
>
> Set.map, Set.empty, ...
> This is how Chris does it in Edison.
> Why isn't this used more?
One could possibly argue that the right solution is to put the
operations in classes? There has
Ross Paterson <[EMAIL PROTECTED]> writes:
>> It shouldn't be too hard to fix this, at least for Latin-1 (full
>> Unicode would be somewhat harder). I'll add it to the TODO list.
> While Haskell's source charset is specified as Unicode, Haskell source
> files don't specify the byte encoding they
Axel Simon <[EMAIL PROTECTED]> writes:
>> There is an IA64 port somewhere, and I suspect other 64-bit
>> architectures as well. Presumably they support >4Gb?
> I wonder if such an effort is worthwhile. If all pointers are suddenly
> twice the size then the footprint of a program roughly doubles.
Axel Simon <[EMAIL PROTECTED]> writes:
>> There is an IA64 port somewhere, and I suspect other 64-bit
>> architectures as well. Presumably they support >4Gb?
> I wonder if such an effort is worthwhile. If all pointers are suddenly
> twice the size then the footprint of a program roughly doubles.
[EMAIL PROTECTED] (Donald Bruce Stewart) writes:
> SimonM may want to comment, but at the moment I think GHC is limited to
> 4G, but only due to lack of 64bit machines/demand on the developers.
There is an IA64 port somewhere, and I suspect other 64-bit
architectures as well. Presumably they sup
(Reply-To: haskell-cafe)
Alastair Reid <[EMAIL PROTECTED]> writes:
>> I have a question about error reporting. You use 'error' quite often. I
>> think that this can cause errors to pop up at strange moments during
>> program evaluation.
> You're right, it can lead to late error messages. For e
"Sean L. Palmer" <[EMAIL PROTECTED]> writes:
> Why has HTML been out for many many years, and yet programming languages
> still use plain ASCII text exclusively? Don't we have similar needs as
> other electronic document manipulators?
So we could write:
foo bar = case bar of
Zot x -> ...
George Russell <[EMAIL PROTECTED]> writes:
> In addition, I suggest that, since it is widely agreed that the instances of
> Enum for Float and Double
And (Ratio a)?
>are highly unsatisfactory
-kzm
--
If I haven't seen further, it is by standing in the footprints of
Malcolm Wallace <[EMAIL PROTECTED]> writes:
>> 5. In Appendix A, the Enum class defn, add comments to explain that the
>> default methods only work for types whose fromEnum/toEnum range fits
>> inside Int.
> I would rather have correct default definitions.
Somebody raised the issue why to/from
George Russell <[EMAIL PROTECTED]> writes:
> (1) succ & pred. These appear for float to correspond to adding or subtracting
> 1.0. (I am finding this out by testing with ghci; it's not specified where
> it should be, in section 6.3.4 of the standard). Because of rounding errors,
Pixel <[EMAIL PROTECTED]> writes:
> Quite a few pbs with overflow on Int too:
> i :: Int
> i = 0x7fff
> i_plus_1 = i+1
> -- ghc : -2147483648
> -- hugs: -2147483648
Given that Int represents modulo arithmetic, this is all right, but
> i_succ = succ i
> -- ghc : *** Exception: Prelud
Juan Carlos Arévalo Baeza <[EMAIL PROTECTED]> writes:
> On Tue, 23 Oct 2001 00:38:23 -0400 (EDT), Mark Carroll wrote:
>> On Tue, 23 Oct 2001, Andre W B Furtado wrote:
>>> What do you all think about activating the mechanism that automatically
>>> includes the name of the list before the subject
jefu <[EMAIL PROTECTED]> writes:
> 2) Every time you get spam, locate all the hosts it came through
>in the header. Check both hostnames and ip addresses as one
>of the common spammer techniques is to give a different hostname
>than the ip address maps to.
Note that spammers add
"riz er" <[EMAIL PROTECTED]> writes:
> howMany :: Int -> Int -> Int -> Int
> howMany n1 n2 n3
> | (n1 > a) && (n2 > a) && (n3 > a) = 3
> | (n1 > a) && (n2 > a) = 2
> | (n1 > a) && (n3 > a) = 2
> | otherwise = 1
> where a = (n1 + n2 + n3)/3
> i get an error message
Lennart Augustsson <[EMAIL PROTECTED]> writes:
> "S. Alexander Jacobson" wrote:
>> Great. So that is something that goes into some library conventions
>> document. Java has a convention that libraries should have reverse domain
>> name structure. Is that how we should use _?
> Yes, I think t
...or how about a web zine along the lines of (the Linux) Kernel Notes
and cousins (http://kt.zork.net/)? This is just a (couple of?) guy(s)
closely following the kernel mailing list, and summarizing, quoting
interesting mail, providing links where appropriate and so on.
Immensely useful for th
Johannes Waldmann <[EMAIL PROTECTED]> writes:
>> ... there have been no submissions accepted in the
>> `application letters' category for the Haskell workshop.
Really?
> a) there ARE no proper real world applications of Haskell
>(only a rather large number of so called pearls)
> b) these t
"Simon Peyton-Jones" <[EMAIL PROTECTED]> writes:
> Wrong, and I hope that the report is already unambiguous on this point.
> If you say 'import A' then you can refer to "A.f" or "f" but definitely
> not "B.f". The module qualifier is the name of the module named in the
> import statement (or its
"Cagdas Ozgenc" <[EMAIL PROTECTED]> writes:
> The following function generates a type error.
>
> headColumnwise :: [a] -> a
> headColumnwise line = [ head line | line <- p ]
Surely, the parameter should be "p"?
> ERROR ch6ex1.hs:14 - Inferred type is not general enough
> *** Expression: he
"Simon Peyton-Jones" <[EMAIL PROTECTED]> writes:
> I propose that hiding something that isn't exported should be
> considered an error. It's not actually harmful but it is misleading.
Or at least a warning? I don't know, but there may be reasons to do
it, say the imported module is under deve
stanley goof <[EMAIL PROTECTED]> writes:
> I am planning to write a text-adventure game in
> haskell.
Right.
> This is the type of game in which you can execute many
> commands like 'take'(to take an object), 'goto' to
> move from a room to another room, 'look'(to see the
> objects in a room),
Juan Carlos Arevalo Baeza <[EMAIL PROTECTED]> writes:
> At 02:35 AM 5/24/2001 +1000, Fergus Henderson wrote:
>> I agree that it would be very nice if Haskell and other FPLs had some
>> equivalent feature, with a nicer syntax. I think you might be able to
>> do a lot of it using ordinary Haskell s
"Taesch, Luc" <[EMAIL PROTECTED]> writes:
> the pretty print return the closing < on the next line, like
>> > where i expect
>
>
>
My guess is that HaXML doesn't validate (using the DTD) or simply
ignores it for pretty printing purposes. If the "Person-XML" e
(Apologies, I forgot to change the subject)
Laszlo Nemeth <[EMAIL PROTECTED]> writes:
> * * * Ketil Malde <[EMAIL PROTECTED]> wrote:
> There is no difference. The 'pipe-syntax' (or pattern guards) gets
> desugared (by the pattern matching compiler) to cas
There's something that I've been wanting to ask sombody about, since
it isn't terribly clear to me. Blatantly hijacking a function from
Julian's code:
> runRandom last max num
> | num > 1 = runRandom (fst new) max (num-1)
> | otherwise = snd new
While ifs are perhaps more intuitive when
Malcolm Wallace <[EMAIL PROTECTED]> writes:
> Proposal 1
> --
> Introduce nested namespaces for modules. The key concept here is to
> map the module namespace into a hierarchical directory-like structure.
> * The use of qualified imports becomes more verbose: for instance
[...]
"C.Reinke" <[EMAIL PROTECTED]> writes:
> So foldl is indeed tail recursive, but this doesn't help if its
> operator isn't strict because the tail recursion only builds up the
> expression to be evaluated. Making strictness explicit by defining a
> variant of foldl that evaluates its accumulator a
Bjorn Lisper <[EMAIL PROTECTED]> writes:
>> Two interpretations of a code are "correct", but one is "more correct"
>> than the other.
> It is quite similar in spirit to the concept of principal type in
> Hindley-Milner type systems. An expression can have many types but
> only one "best" (most g
Brian Boutel <[EMAIL PROTECTED]> writes:
> * most usage of (+), (-), (*) is on numbers which support all of them.
Yes, but the problem is that the way this is implemented is a nuisance
and a hindrance to those who wants to apply these operators to
different data types. Also, it means functions
Brook Conner <[EMAIL PROTECTED]> writes:
> Do you think the cookbook would be better as its own book?
Perhaps it could? I think it's a natural component in a "nutshell"
book, but it seems clear that there's tons of example programs that
would be immensely useful as well-documented howtos.
[Coo
Brook Conner <[EMAIL PROTECTED]> writes:
> Inspired by the recent discussions of what kinds of books would encourage the
> spread of Haskell, I whipped up a draft table of contents for "Haskell in a
> Nutshell."
Let's see. It all depends on what you put into the chapters, of
course, but you see
"Karl M. Syring" <[EMAIL PROTECTED]> writes:
>> Mind if I "me too" a bit? I had just read the SICP, and I too found
>> that the Gentle Introduction served well as an introduction to the
>> Haskell syntax.
> If you start out with zero knowledge in functional programming, as I do, the
> GITH is r
George Russell <[EMAIL PROTECTED]> writes:
> I think Paul is being unduly modest. I found it very useful when I first learnt
> Haskell. But I did already know ML, so maybe the "Gentle Introduction" would be
> harder going for someone who didn't know anything about functional programming.
Mind
George Russell <[EMAIL PROTECTED]> writes:
> > As a result, I seldom write > > "private" functions at top-level,
> > and I think the situation might be > > true for other functional
> > programmers as well.
> It isn't true for me.
Me neither. I simply disregard the whole export list during
Koen Claessen <[EMAIL PROTECTED]> writes:
> Take a look at the following "program snippet" (a very
> popular word at last week's ICFP :-):
>
> > bfReplace :: [b] -> Tree a -> Tree b
> > bfReplace xs = deQ . bfReplaceQ xs . singletonQ
>
> Now we just have to define bfReplaceQ.
If
Chris Angus <[EMAIL PROTECTED]> writes:
> I was wondering if anyone had thought of making a Sax-like
> interface based on lazy evaluation. where tokens are
> processed and taken from a (potentially) infinite stream
Sure. While barely able to follow discussions about monadic parser
combinators
Ketil Malde <[EMAIL PROTECTED]> writes:
I guess I owe it to the list to elaborate on my stupidity here.
> Unfortunately, and I'm going to agree with graham here, the resulting
> program uses a lot of memory (parsing about one meg of HTML, producing
> about 200K of re
1 - 100 of 136 matches
Mail list logo