felipe.lessa:
I've written it to run over lists, but it would not be difficult to
make it run over ByteStrings instead, and exploit the 'no-copying'
effect on the bits of the stream which were not modified, which would
be very handy for programs processing large bytestrings.
I wonder if
trebla:
Andrew Coppin wrote:
Personally, I just try to avoid *all* language extensions - mainly
because most of them are utterly incomprehensible. (But then, perhaps
that's just because they all cover extremely rare edge cases?)
Haskell is an extremely rare edge case to begin with.
trebla:
Donald Bruce Stewart wrote:
Give #haskell is a far larger community than:
#lisp
#erlang
#scheme
#ocaml
As well as
#java
#javascript
#ruby
#lua
#d
#perl6
Maybe we need to reconsider where the (FP) mainstream is now? :-)
I
drtomc:
I was explaining Haskell to a perl/python hacking friend recently and
characterized things thus:
Perl is a horrible language with fantastic libraries.
Haskell is a fantastic language with horrible libraries.
Actually, many of the libraries that exist for Haskell *are*
fantastic,
p.f.moore:
On 05/07/07, Jonathan Cast [EMAIL PROTECTED] wrote:
Can't say I agree. I've been learning Python, and have been very
un-impressed
so far with its library coverage, which I would rate no better than (in
terms
of the POSIX bindings, worse than) Haskell.
It probably depends on
drtomc:
On 7/6/07, Lukas Mai [EMAIL PROTECTED] wrote:
Hello, cafe!
Have you been reading my mind? See the other recent Cafe thread (um,
titled something about System.Exit).
Here's my solution:
...
If you've got small examples illustrating how to use the various
concurrency abstractions,
andrewcoppin:
Jonathan Cast wrote:
On Thursday 05 July 2007, Andrew Coppin wrote:
...OK, anybody have a solution that works in Haskell 98?
Rank-2 types are perhaps /the/ most common, widely accepted extension to
Haskell 98, after the approved addendum for FFI and the draft
phil:
On Sun, Jul 01, 2007 at 06:07:13PM +0100, Andrew Coppin wrote:
I haven't actually tried, but presumably a TCP connection is represented
in the same way as a file, and so has the same problems.
Basically doing binary I/O seems to be one of those things that in Haskell
falls into the
drtomc:
Anyone trying to do any of this?
I've done some work in this area. I'm particularly interested in
manipulating ASN.1 in haskell. Actually, my first use of Parsec was an
ASN.1 parser. I'd done one previously in Spirit (the Boost C++ rip-off
of parsec), but semantic actions were
phil:
On Wed, Jul 04, 2007 at 09:02:15PM +1000, Donald Bruce Stewart wrote:
phil:
On Sun, Jul 01, 2007 at 06:07:13PM +0100, Andrew Coppin wrote:
I haven't actually tried, but presumably a TCP connection is represented
in the same way as a file, and so has the same problems.
Basically
phil:
On Wed, Jul 04, 2007 at 09:44:13PM +1000, Donald Bruce Stewart wrote:
Binary instances are pretty easy to write. For a simple data type:
instance Binary Exp where
put (IntE i) = do put (0 :: Word8)
put i
dm.maillists:
On Thursday 05 July 2007 11:20, Michael Vanier wrote:
Again, I'm sure this has been done before (and no doubt better); I'd
appreciate any pointers to previous work along these lines.
Takusen is, if I recall correctly, based around a generalised fold supporting
accumulation
drtomc:
On 7/4/07, Donald Bruce Stewart [EMAIL PROTECTED] wrote:
Can we do a cheap bytestring binding to libxml, to avoid any initial
String processing?
For my part, it's not too big an issue. A version of HaXml or at least
Parsec built on top of ByteString would be a good start. I know
aeyakovenko:
inlining some of the functions definitely gave me a boost, so i am
about 8.5 times slower then openssl sha1sum. I dont really understand
the core output, but after inlining i got a completely different
profile output, i am guessing its because the cost of the inlined
functions
Interested in competing in the ICFP 2007 programming contest -- the
hackers contest of choice!
http://www.icfpcontest.org
There's 2000 people on this mailing list, and 350 people in #haskell, we
must be able to put together a few decent teams out of that talent
pool
To help people get
aeyakovenko:
So I tried implementing a more efficient sha1 in haskell, and i got to
about 12 times slower as C. The darcs implementation is also around
10 to 12 times slower, and the crypto one is about 450 times slower.
I haven't yet unrolled the loop like the darcs implementation does, so
clawsie:
i have written a small haskell program to solve a problem many users
of freebsd may have - knowing what ports have been updated after a
daily/weekly etc cvsup. this is a trivial bit of coding hardly worth
attention, but if it might be of use to you, you can find it here:
consalus:
A while back I saw a toy tcl interpreter in 550 lines of C called
'picol'. I was looking for a simple language to implement in haskell,
so I made my own toy tcl interpreter. It was surprisingly easy to
make, thanks to the magic of Haskell and Bytestrings. :) It handles a
few things
bulat.ziganshin:
Hello Donald,
Wednesday, June 27, 2007, 6:37:07 AM, you wrote:
I also know Bulat Ziganshin had put together a nice-looking Streams
library (http://unix.freshmeat.net/projects/streams/) based on John
Goerzen's previous HVIO work, but I wasn't sure if the ByteString
gracjanpolak:
Hi all,
I'm pleased to announce the first public release of Scripting.Lua.
The package hslua-0.1 contains Haskell FFI bindings for a Lua interpreter
along with some Haskell utility functions simplifying Haskell to Lua and
Lua to Haskell calls. Full Lua interpreter is
chad.scherrer:
I've never used sockets before, but I need to now, and I need to be
able to get a lot of data quickly. I was thinking about doing
something like this (below), but I'm wondering if there's a way that
would be faster. Is the obvious way of doing this the right way? I'm
happy to
tittoassini:
Hi,
to load an Haskell symbol at run-time is still necessary to use the load
functions from the hs-plugins library (System.Plugins.Load) or is there some
function in the GHC API that does the same job?
yes, definitely possible. i think Lemmih put an example on the wiki a
chad.scherrer:
Ok, cool. FWIW, the current documentation for Network says:
For really fast I/O, it might be worth looking at the hGetBuf and
hPutBuf family of functions in System.IO.
But this looked pretty low-level to me, and I figured it might be outdated.
I also know Bulat Ziganshin
gwern0:
Hey everyone. So I've been learning Haskell for a while now, and I've
found the best way to move from theory to practice is to just write
something useful for yourself. Now, I'm keen on editing Wikipedia and
I've long wanted some way to stop links to external websites from
breaking on
andrewcoppin:
Bulat Ziganshin wrote:
Hello Andrew,
definitive reading: Tackling the awkward squad: monadic input/output,
concurrency, exceptions, and foreign-language calls in Haskell
http://research.microsoft.com/Users/simonpj/papers/marktoberdorf/marktoberdorf.ps.gz
I've read
...OK...so how do I make Haskell go faster still?
Presumably by transforming the code into an ugly mess that nobody can
read any more...?
http://haskell.org/haskellwiki/Performance
-- Don
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
bayer:
I couldn't find a compile-time here document facility, so I wrote one
using Template Haskell:
Very nice! You should wrap it in a little .cabal file, and upload it to
hackage.haskell.org, so we don't forget about it.
Details on cabalising and uploading here:
jon:
On Friday 22 June 2007 19:54:16 Philip Armstrong wrote:
On Fri, Jun 22, 2007 at 10:11:27PM +0400, Bulat Ziganshin wrote:
btw, *their* measurement said that ocaml is 7% faster :)
Indeed. The gcc-4.0 compilied binary runs at about 15s IIRC, but it's
still much better than 7% faster
bf3:
Wow thanks for all the info! This certainly can get me started.
And yet I have some more questions (sorry!):
- Unfortunately this project won't be open source; if my first tests are
successful, I will try to convince my employer (who wants to develop such a
graphical language) to use
ttmrichter:
On Wed, 2007-20-06 at 15:21 +1000, Donald Bruce Stewart
wrote:
-- unsigned char *MD5(const unsigned char *d, unsigned long n, un
signed char *md);
foreign import ccall openssl/md5.h MD5 c_md5
:: Ptr CChar - CULong - Ptr CChar - IO (Ptr Word8
eeoam:
Bryan O'Sullivan wrote:
Eric wrote:
I'm writing a simple HTTP server and am trying to implement the POST
method.
That's a rather general problem statement, indeed :-) For an
application like this, I'd suggest that explicit resource management
is the way to go, and that you
jeff:
I've read the documentation for some of the marshalling packages out
there for Haskell, and I'm left confused as to which one I should be
using and how to actually do what I want to do. I have a file, a
little over 2gb, of packed data in the format
(recordcount) records of:
aeyakovenko:
$ time ./md5sum ./md5sum
[105,252,52,138,187,192,216,17,225,123,185,3,124,101,86,132]
real0m4.790s
user0m3.688s
sys 0m0.492s
$ time md5sum ./md5sum
69fc348abbc0d811e17bb9037c655684 ./md5sum
real0m0.023s
user0m0.000s
sys 0m0.008s
this is my
dons:
aeyakovenko:
$ time ./md5sum ./md5sum
[105,252,52,138,187,192,216,17,225,123,185,3,124,101,86,132]
real0m4.790s
user0m3.688s
sys 0m0.492s
$ time md5sum ./md5sum
69fc348abbc0d811e17bb9037c655684 ./md5sum
real0m0.023s
user0m0.000s
sys
stefanor:
On Wed, Jun 20, 2007 at 01:24:00PM +1000, Donald Bruce Stewart wrote:
aeyakovenko:
$ time ./md5sum ./md5sum
[105,252,52,138,187,192,216,17,225,123,185,3,124,101,86,132]
real0m4.790s
user0m3.688s
sys 0m0.492s
$ time md5sum ./md5sum
aeyakovenko:
$ time ./md5sum ./md5sum
[105,252,52,138,187,192,216,17,225,123,185,3,124,101,86,132]
real0m4.790s
user0m3.688s
sys 0m0.492s
$ time md5sum ./md5sum
69fc348abbc0d811e17bb9037c655684 ./md5sum
real0m0.023s
user0m0.000s
sys
dons:
-- Fast md5 using OpenSSL and non-copying bytestrings
md5sum :: B.ByteString - String
md5sum p = unsafePerformIO $ B.unsafeUseAsCStringLen p $ \(ptr,n) - do
digest - c_md5 ptr (fromIntegral n) nullPtr
liftM concat $ forM [0..15] $ \n - do
lemming:
On Sun, 17 Jun 2007, Donald Bruce Stewart wrote:
simonmarhaskell:
Henning Thielemann wrote:
The program is compiled with GHC-6.4 and option -O2, CPU clock 1.7 GHz.
ByteString is much faster with GHC 6.6, IIRC. We optimised the
representation of ForeignPtr
simonmarhaskell:
Henning Thielemann wrote:
The program is compiled with GHC-6.4 and option -O2, CPU clock 1.7 GHz.
ByteString is much faster with GHC 6.6, IIRC. We optimised the
representation of ForeignPtr, and ByteString takes advantage of that. I
recommend upgrading.
Yes, a 2x
newsham:
I wanted to point out:
http://exitlist.torproject.org/
written in Haskell. I haven't seen any announcements or info on this list
(apologies if someone else mentioned it already). For the record, I'm not
affiliated with the project in any way.
Is the source available?
--
dons:
sic:
* Andrew Coppin [EMAIL PROTECTED] [070608 02:45]:
Bayley, Alistair wrote:
[[1]mailto:[EMAIL PROTECTED] On Behalf Of Andrew Coppin
Donald Bruce Stewart wrote:
Some things to remember using Doubles:
* {-# OPTIONS -fexcess-precision
andrewcoppin:
Donald Bruce Stewart wrote:
Some things to remember using Doubles:
* {-# OPTIONS -fexcess-precision #-}
* -fvia-C
* -fbang-patterns
* -optc-O2 -optc-mfpmath=sse -optc-msse2
* -optc-march=pentium4
1. What do all those things do?
Check the GHC
Alistair_Bayley:
[mailto:[EMAIL PROTECTED] On Behalf Of Donald
Bruce Stewart
3) -fbang-patterns
Better than `seq`
Better in the more convenient to write sense, right? AFAIUI, seq and
bang patterns should be equivalent.
Yes, in the 'more convenient' sense. Adding strictness
mdanish:
Hello,
I've been playing with the INTEST problem on SPOJ which demonstrates
the ability to write a program which processes large quantities of
input data. http://www.spoj.pl/problems/INTEST/
But when I make a slight modification, the program chews up a ton more memory
and
dons:
mdanish:
Hello,
I've been playing with the INTEST problem on SPOJ which demonstrates
the ability to write a program which processes large quantities of
input data. http://www.spoj.pl/problems/INTEST/
But when I make a slight modification, the program chews up a ton more
clawsie:
i recently saw a (yet-another) benchark comparing various languages:
http://www.timestretch.com/FractalBenchmark.html
while no haskell example was listed, i thought i would try a naive
implementation myself for comparison. it is available here:
dons:
dons:
mdanish:
Hello,
I've been playing with the INTEST problem on SPOJ which demonstrates
the ability to write a program which processes large quantities of
input data. http://www.spoj.pl/problems/INTEST/
But when I make a slight modification, the program chews
lutz:
Does anyone have a haskell compiler for True64 (formerly known as OSF/1) on
Alpha hardware?
I'm currently unable to compile the first bootstrap compiler.
Any hint which compiler should I start with?
I'll send detailed error reports only if I do not succeed in the next hours.
I
Phlex:
Hello all,
I'm coming from the OO world, and there's something i don't quite
understand in the way haskellers manipulate data (as all functional
programmers i guess).
Let's say i have a deep nested data structure.
Universe containing galaxies, containing solar systems,
apfelmus:
Phlex wrote:
Donald Bruce Stewart wrote:
Imagine updating a node in a tree by just detaching and reattaching a
pointer.
[1] [1]
/ \ / \
[2] [3] update node 5 [2] [3]
/ \ with value 7
almeidaraf:
On 6/3/07, Rafael Almeida [EMAIL PROTECTED] wrote:
The site seems to be asking for the internal floating point
representation. So it doesn't matter if it's IEEE 754, if the ints are
2-complements, or whatever. I used this code as a quick hack for one of
my programs, but I think
bulat.ziganshin:
Hello Andrew,
Thursday, May 31, 2007, 11:47:28 PM, you wrote:
(Otherwise... wasn't there some library somewhere for serialising values
in binary?)
Binary, AltBinary (see latest HCAR), just an example using AltBinary:
main = do
let s = encode (1.1::Float)
jules:
Donald Bruce Stewart wrote:
let s = encode (1.1 :: Float)
:t s
s :: Data.ByteString.Lazy.ByteString
s
LPS [\NUL\NUL\140\204\205\255\255\255\255\255\255\255\233]
decode s :: Float
1.1
But doesn't Data.Binary serialise to a guaranteed
andrewcoppin:
Donald Bruce Stewart wrote:
See also the older NewBinary,
http://hackage.haskell.org/cgi-bin/hackage-scripts/package/NewBinary-0.1
Now that's just ironic...
Incidentally, I've been thinking. You *might* want the binary
representation of things if you were going
stefan:
Al,
Has there been any work on extending Haskell's type system with
structural subtyping?
Koji Kagawaga. Polymorphic variants in Haskell. In Andres Loeh,
editor, Proceedings of the 2006 ACM SIGPLAN Workshop on Haskell,
Portland, Oregon, USA, September 17, 2006, pages
rwiggerink:
I'm pretty new to Haskell, so forgive me if my question is due to my
non-functional way of thinking...
I have the following code:
module Main where
main = print solution
solution = solve 100
solve d = countUniqueFractions d 2 1 0
canBeSimplified (a,b) = gcd a
jon:
On Wednesday 30 May 2007 06:58:36 Ketil Malde wrote:
On Tue, 2007-05-29 at 14:05 -0500, Doug Kirk wrote:
I *want* people (and companies) to move to Haskell
As a complete noob considering making a commercial venture into Haskell, may
I
ask what people's opinions are on this? Are
kahl:
P.S. Have some cute code:
Control.Monad.Fix.fix ((1:) . scanl (+) 1)
Cute!
But what an un-cute qualified name:
:t Control.Monad.Fix.fix
Control.Monad.Fix.fix :: (a - a) - a
Has nothing to do with monads,
and would perhaps be considered as ``out of
We got the names wrong!
data PLZ a = AWSUM_THX a | O_NOES String
instance Monad PLZ where
return= AWSUM_THX
fail = O_NOES
O_NOES s= _ = O_NOES s
AWSUM_THX x = f = f x
Thanks to mauke on #haskell.
-- Don
d.w.mead:
is that your implementation of LOLCODE?
:P
On 5/29/07, Donald Bruce Stewart [EMAIL PROTECTED]
wrote:
We got the names wrong!
data PLZ a = AWSUM_THX a | O_NOES String
instance Monad PLZ where
return= AWSUM_THX
vincent:
i see that the definition of fix (from Control.Monad.Fix) could not be
any simpler:
fix f = let x = f x in x
same goes for the type:
Prelude :t Control.Monad.Fix.fix
Control.Monad.Fix.fix :: (a - a) - a
it's just that i find it difficult to get concrete intellectual
pvolgger:
I wonder if there are any Coding Standards or Coding Conventions for
Haskell. Does anybody know something about it?
We've collected some style guides on the wiki. You could also look at
projects whose code you think is in good style.
http://haskell.org/haskellwiki/Category:Style
conrad:
On 28/05/07, Donald Bruce Stewart [EMAIL PROTECTED] wrote:
Our small little window manager, xmonad, also has a pretty strict style
guide.
where? Perhaps I need coffee, but I couldn't find this in the source
(xmonad, x11-extras, XMonadContrib) or documentation links from
xmonad.org
bulat.ziganshin:
Hello Bryan,
Sunday, May 27, 2007, 3:30:50 AM, you wrote:
I think, given my simple algorithm that means that (==) for
ByteStrings is slower than (==) for String. Is this possible?
Yes indeed. Over ByteStrings, (==) is implemented as a call to memcmp.
For small
junkywunky:
type Person = (NI, Age, Balance)
type Bank = [Person]
credit :: Bank - [Person]
credit [(a,b,c)] = [(a,b,c)]
This code works when I type in:
credit [(1,2,3)]
but doesn't work when I type in:
credit [(1,2,3),(4,5,6)]
You're pattern matching in 'credit' on a list of
junkywunky:
That's the thing. I want to return a list of people who are not overdrawn.
Something like:
type NI = Int
type Age = Int
type Balance = Int
type Person = (NI, Age, Balance)
type Bank = [Person]
credit :: Bank - [Person]
credit [(a,b,c)] = [(a,b,c)] if c = 0
isaacdupree:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Isaac Dupree wrote:
The expression is bound to a random top level identifier (harmless to
guess)
What about the non-recursive
case ...expr... of x - take 2048 (show x)
this way expr can't refer to x (it doesn't at
aneumann:
-BEGIN PGP SIGNED MESSAGE-
Hash: RIPEMD160
Hi,
I installed the Network.CGI package and tried to compile the Hello World
example on my Ubuntu machine.
ghc cgi.hs -o cgi
Missing --make to link against the cgi and network and mtl packages.
Also, -O or -O2, you may as
andrewcoppin:
Since the online lambdabot still doesn't seem to want to talk to me,
I've been thinking about how I might rectify the situation...
Apparently GHC has a flag that makes it execute a Haskell expression
directly. For example,
C:\ ghc -e map (2*) [1,2,3]
[2,4,6]
Now, if I
On 26/05/07, Matthew Sackman [EMAIL PROTECTED] wrote:
(On the other hand, I don't know of anyone outside immediate
haskellers using Darcs.)
Good idea to get some data on this, instead of speculating. Let's do that.
A quick google reveals the Haskell crew is far from alone as users.
claus.reinke:
Oh, but there is the *minor* detail that I am literally allowing
unauthenticated users to perform arbitrary code execution. For example,
..
AFAIK, Lambdabot dissalows any expression that performs IO. In Haskell,
this is beautifully easy: reject any expression having an IO type.
it would really be nice if someone would sit down and sort this all out
in detail. there'd still be no guarantee that such a Haskell sandbox was
totally safe, but at least all issues and solutions could be shared, making
it as safe as the community knows how.
The #haskell people have been
isaacdupree:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Donald Bruce Stewart wrote:
Lambdabot uses 1) type guarantee of no-IO at the top level, along with
2) a trusted module base (pure module only, that are trusted to not
export evil things), as well as 3) restricting only to H98
overdrigzed:
As far as I know, hs-plugins works by taking an
expression, writing it
to a file, calling GHC to parse it, transform it to Core,
optimise it,
transform it to STG, optimise it, transform it to C--,
optimise it,
transform it to ANSI C,
claus.reinke:
The #haskell people have been working on this for about 3 years now.
The result is the 'runplugs' program, which I've talked about in
previous mails.
http://www.cse.unsw.edu.au/~dons/code/lambdabot/scripts/RunPlugs.hs
It uses hs-plugins for the evaluation, along with the
bos:
Jason Dagit wrote:
I think, given my simple algorithm that means that (==) for
ByteStrings is slower than (==) for String. Is this possible?
Yes indeed. Over ByteStrings, (==) is implemented as a call to memcmp.
For small strings, this loses by a large margin because it has to go
leaveye.guo:
Hi.
In GHCi ver 6.6, why this happens ?
Prelude Data.ByteString Data.ByteString.pack $! Prelude.map (`rem` 256) $
[0..511]
*** Exception: divide by zero
Interesting...
Is that just,
Data.ByteString.pack $ [0..255] ++ [0..255]
?
-- Don
leaveye.guo:
Hi.
In GHCi ver 6.6, why this happens ?
Prelude Data.ByteString Data.ByteString.pack $! Prelude.map (`rem` 256) $
[0..511]
*** Exception: divide by zero
It's the use of `rem` on Word8, by the way:
Prelude (0 `rem` 256) :: Data.Word.Word8
*** Exception: divide by
dons:
leaveye.guo:
Hi.
In GHCi ver 6.6, why this happens ?
Prelude Data.ByteString Data.ByteString.pack $! Prelude.map (`rem` 256) $
[0..511]
*** Exception: divide by zero
It's the use of `rem` on Word8, by the way:
Prelude (0 `rem` 256) :: Data.Word.Word8
***
ketil:
On Fri, 2007-05-25 at 17:33 +1000, Donald Bruce Stewart wrote:
Sorry, I should clarify, think about how to represent:
256 :: Word8
So the error isn't really divide by zero, but overflow. I've been
bitten by this, too, and L.Guo should count him/herself lucky to get
greenrd:
The following Haskell 98 module implements a generalisation of
Prelude.ShowS for any type. Should be pretty easy to incorporate this
into code which currently uses the list monad non-trivially, and get
better performance - but can this be right? Surely someone would have
published
leaveye.guo:
Hi MailList Haskell-Cafe:
Till now, which module / package / lib can i use to access binary
file ? And is this easy to use in GHC ?
Data.Binary? Or perhaps just Data.ByteString, available on hackage,
leaveye.guo:
Thanks for your suggestion, and sorry for the subject.
I have read the introduction of Data.ByteString, it is helpful.
And also, there is one problem left. When i read a binary file, data
is truncated at the charactor EOF.
Which function could do this work correctly ?
Hmm.
marco-oweber:
On Thu, May 24, 2007 at 02:38:05PM +0800, L.Guo wrote:
Thanks for your suggestion, and sorry for the subject.
I have read the introduction of Data.ByteString, it is helpful.
And also, there is one problem left. When i read a binary file, data is
truncated at the
leaveye.guo:
to Ketil :
Tring openBinaryFile, I notice that I cannot make one usable buffer,
just because I can not find one function to malloc a memory or just
get one change-able buffer.
:-$
No 'malloc' here in Haskell land: that's done automatically. Recall
that 'getContents' will
leaveye.guo:
To read the handle openBinaryFile returns, both the hGetBuf and
hGetBufNonBlocking needs one parameter _buf_ of type Ptr a.
I can not get one data of that type.
In the doc, there is only nullPtr, and also some type cast functions.
I failed to find some other buffer-maker
bos:
I'll condense my remaining replies to this thread into a single message,
to save people a little noise.
I'd just add that the response is literally overwhelming! Some 100-odd
volunteers to review, and a lot of mail besides.
Please bear with us as we try to surface under this mountain of
Alistair_Bayley:
I'm sure that I can quite reliably hit the command editor
keybindings I
use many, many times faster than if I had to select them
from a menu.
Note that the claimed time-consuming part is not to actually press the
keybinding, but to chose and remember which one
prstanley:
Hi
What is the rationale behind currying? is it for breaking subroutines
into
pure one-to-one mappings?
We don't have 'subroutines' as such, but otherwise yes. Also, it gives us
partial application - we don't have to apply all the parameters at once,
and we can do
When working on xmonad, we're trying to produce very clean, correct
code -- a window manager that just works. To do this, we're looking to
employ more static checking tools to the code base. Currently we use:
* QuickCheck (checks high level window manager behaviour)
* Catch (Neil's
andrewcoppin:
Greetings.
I was thinking... we already have Lambdabot sitting in an IRC channel.
How hard would it be to mangle Lambdabot to the point where it works
over HTTP? You know - so you could type some Haskell into a form on a
Lambdabot web server is here:
andrewcoppin:
Hi everybody.
Is there any circumstances under which an expression like map (2*) would
perform an in-place update rather than generating a new list? (Obviously
Yes, should be fine, if the result is consumed. We have fusion
frameworks that do this.
this depends on which
matt:
It occurred to me that the predicate will generally be a monadic function
itself, so here's a
refined version:
:: Monad m = (a - m Bool) - (a - m a) - a - m a
untilM pred f x = do c - pred x
if c then return x
else f x = untilM pred f
lpenz:
Hi
I made a program that detects user presence in a linux box by checking
for keyboard interruptions in /proc/interrupts.
Problem is, it is supposed to run for a long time, and it keeps about
40MB for itself.
Yeah, this is one more help me with this memory problem mails...
eeoam:
H|i,
Does anyone know of a simple and straightforward way to use global
variables in Haskell?
E.
The usual way is to run the code that needs a global variable in a State monad.
The next answer is: you don't really need global variables, since you
don't have mutable variables
cyril.schmidt:
I noticed recently that the website of CUFP conference (Commercial Uses of
Function Programming), which used to be at http://www.galois.com/cufp,
is not accessible anymore.
Does anybody know where it moved?
Try http://cufp.galois.com/
-- Don
joelr1:
Would someone kindly explain why we need co-arbitrary in QuickCheck
and how to define it?
Generating random function generators.
A nice explanation was given recently on the programming subreddit:
The CoArbitrary class continues to confuse me
aneumann:
-BEGIN PGP SIGNED MESSAGE-
Hash: RIPEMD160
Are there any good books about intermediate to advanced Haskell? The
descriptions here http://haskell.org/haskellwiki/Books_and_tutorials
aren't very helpful.
Not in real-world paper form, yet.
Mostly advanced techniques and
Anyone tried editing haskell.org's wiki as text, using:
http://wikipediafs.sourceforge.net/
WikipediaFS is a mountable Linux virtual file system that enables you
to deal with Wikipedia (or any Mediawiki-based site) articles as if they
were real files. It is thus possible to use a real text
---
Haskell Weekly News
http://sequence.complete.org/hwn/20070507
Issue 62 - May 07, 2007
---
Welcome to issue 62 of HWN, a weekly newsletter covering
101 - 200 of 594 matches
Mail list logo