That's why I said for appropriate g and f. But I see that my
wording was misleading.
However you can say:
foldl' oplus alpha bs =(foldr f id bs) alpha where
f a g = \alpha - g (alpha `oplus` a)
foldr' oplus alpha bs = (foldl f id bs) alpha where
f g a = \alpha - g (a `oplus`
I was using the transformers but still had to implement the Applicative
instance of State
This package contains an applicative instance for StateT but not for State
On Sat, Mar 14, 2009 at 3:05 AM, Henning Thielemann
lemm...@henning-thielemann.de wrote:
On Thu, 12 Mar 2009, Peter Verswyvelen
On Sat, Mar 14, 2009 at 2:36 AM, Henning Thielemann
lemm...@henning-thielemann.de wrote:
a lot. However, isn't this halfheartedly since we all wait for full
dependent types? :-)
Well, in C++ one can already use the numerical values with templates for
achieving a lot of compile time
I've posted a new version, 1.0.1, that has a usage message if you run it
with no arguments.
There is a package for Windows now (not just a binary) as well as Linux.
Both packages include documentation and example programs.
Thanks for pointing that out!
On Fri, Mar 13, 2009 at 1:31 AM, Wolfgang
I am trying install a package using cabal-install however the package
requies an older version of QuickCheck and one of the required packages
requires the latest version:
$ cabal fetch Reactive
Resolving dependencies...
cabal.exe: cannot configure Stream-0.3.1. It requires QuickCheck =2.0
For
I'm getting a runtime failure Error in array index. This causes ghci
to exit.
Is there a way to get it to break instead, so I can find out which
function is failing?
--
Colin Adams
Preston Lancashire
___
Haskell-Cafe mailing list
Great ! I'm just starting with Vim so I'm not sure if I could
contribute. But I definitely will look into the sources. Thanks!
Pavel
On 13.03.2009, at 21:44, andy morris wrote:
2009/3/13 Pavel Perikov peri...@gmail.com:
Hi café !
I googled for some kind of vim support for cabal but found
I have added UAProd-based Binary instances to my copy of the uvector
repo at http://patch-tag.com/publicrepos/pumpkin-uvector . I have some
extensive tests (added to the existing tests directory) of things in
there and they seem to be mostly sane.
The Binary code isn't at all pretty right now,
Henning Thielemann wrote:
Of course, style is a matter of taste. So there are as many good styles
as programmers and there won't be an official style guide, I'm afraid.
While that is true, it's no valid reason to not have a style guide.
Sun's style guide for Java has been very successful,
Benjamin L.Russell wrote:
Why not ask new users to identify letters in a random bitmapped image
of a string, as is commonly done? Then any new user who still
registers and starts submitting spam can be tracked and moderated.
If this doesn't work out we can always use hackage's approach: have
Hello Colin,
Saturday, March 14, 2009, 11:39:41 AM, you wrote:
I'm getting a runtime failure Error in array index. This causes ghci
to exit.
Is there a way to get it to break instead, so I can find out which
function is failing?
i recall two techniques - one is trivially define your own
Henning Thielemann wrote:
How long will the Wiki account registration be disabled? Would it be
possible to ask a question, that real Haskellers could easily answer,
but a spambot cannot? E.g. What's Haskell's surname?
It will be re-enabled when an appropriate extension to MediaWiki is
You can use the ghci debugger
http://www.haskell.org/ghc/docs/latest/html/users_guide/ghci-
debugger.html
it can set breakpoints on exceptions.
Am 14.03.2009 um 09:39 schrieb Colin Paul Adams:
I'm getting a runtime failure Error in array index. This causes ghci
to exit.
Is there a way
Hi everybody,
Just a quick update on the fundraising drive.
We are trying to raise $1000 to help pay for travel to the upcoming
Haskell hackathon (the second of our biannual darcs hacking sprints).
So far we have raised $280, so we're almost a third of the way there.
Think you can help?
Details
Are there some known ways to define hashing (or any other) functions over
equivalence classes? I.e.
a ~ b = hash(a) == hash(b)
where (~) is some equivalence relation. For example, you might want to
hash lambda terms modulo alpha-equivalence or hash logical terms with
respect to commutativity
I'm getting a runtime failure Error in array index. This causes ghci
to exit.
Is there a way to get it to break instead, so I can find out which
function is failing?
i recall two techniques - one is trivially define your own (!) and
print index at least. another is to use ghc profiling with
Daniel Peebles ha scritto:
I have added UAProd-based Binary instances to my copy of the uvector
repo at http://patch-tag.com/publicrepos/pumpkin-uvector . I have some
extensive tests (added to the existing tests directory) of things in
there and they seem to be mostly sane.
Thanks for the
Hi Henning
On 14 Mar 2009, at 01:36, Henning Thielemann wrote:
On Tue, 10 Mar 2009, Conor McBride wrote:
Apologies for crossposting. Please forward this message
to individuals or lists who may be interested. In addition
to the recently advertised PhD position at Strathclyde on
Reusability
Am Samstag, 14. März 2009 08:19 schrieb Peter Verswyvelen:
Well, in C++ one can already use the numerical values with templates for
achieving a lot of compile time computations.
So I would be very happy to have this feature in Haskell. It might also be
good research towards full dependent
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
I am using Data.Binary in a couple of projects, but I have found its stack
and memory usage very hard to control. Its very common that decoding a map
or list of non-trivial size uses up all available RAM, or causes
Henning Thielemann lemm...@henning-thielemann.de wrote:
On Fri, 13 Mar 2009, Benjamin L.Russell wrote:
Why not ask new users to identify letters in a random bitmapped
image of a string, as is commonly done?
I assume, because those images are
1) not accessible by blind people
2)
Grzegorz Chrupala wrote:
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
Yes. binary-strict is one alternative:
http://hackage.haskell.org/cgi-bin/hackage-scripts/package/binary-strict
I am using Data.Binary in a couple of projects, but I have found
On Sat, Mar 14, 2009 at 1:37 PM, Grzegorz Chrupala
grzegorz.chrup...@computing.dcu.ie wrote:
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
I am using Data.Binary in a couple of projects, but I have found its stack
and memory usage very hard to control. Its
Svein Ove Aas ha scritto:
On Sat, Mar 14, 2009 at 1:37 PM, Grzegorz Chrupala
grzegorz.chrup...@computing.dcu.ie wrote:
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
I am using Data.Binary in a couple of projects, but I have found its stack
and memory usage
Hi Wolfgang
On 14 Mar 2009, at 12:00, Wolfgang Jeltsch wrote:
Am Samstag, 14. März 2009 08:19 schrieb Peter Verswyvelen:
Well, in C++ one can already use the numerical values with
templates for
achieving a lot of compile time computations.
So I would be very happy to have this feature in
---
Haskell Weekly News
http://sequence.complete.org/hwn/20090314
Issue 109 - March 14, 2009
---
Welcome to issue 109 of HWN, a newsletter covering
Adrian,
That's why I said for appropriate g and f. But I see that my
wording was misleading.
Thanks for following up! I had thought you were arguing that foldl and
foldr were easily and intuitively interchangeable; they're surely not so
for beginners.
Now I think you're arguing that given
Hi,
can someone please point me to error handling examples with takusen?
I try to run a piece of code with takusen but just get the very sparse
Database.InternalEnumerator.DBException
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
On Saturday 14 March 2009 8:12:09 am Conor McBride wrote:
Rome wasn't burnt in a day.
Of course I want more than just numerical indexing (and I even
have a plan) but numeric constraints are so useful and have
so much of their own peculiar structure that they're worth
studying in their own
Claus == Claus Reinke claus.rei...@talk21.com writes:
Claus None of which is satisfactory. You might also want to add
Claus yourself to this ticket:
Clausindex out of range error message regression
Claus http://hackage.haskell.org/trac/ghc/ticket/2669
How do I do that?
--
Adrian == Adrian Neumann aneum...@inf.fu-berlin.de writes:
Adrian You can use the ghci debugger
http://www.haskell.org/ghc/docs/latest/html/users_guide/ghci-
Adrian debugger.html
Adrian it can set breakpoints on exceptions.
So i tried adding the -fbreak-on-error flag. It made
I can't manage to upload files to the Haskell wiki. I've tried
different browsers, different internet connections, different
machines, different operating systems, and different user accounts -
all without success. Is this a new anti-spam measure?
This is slightly annoying. I was looking
Am Samstag, 14. März 2009 14:51 schrieb Conor McBride:
Conor, is Epigram currently under development?
We've even stopped working on the engine and started working on the chassis.
I'm in an intensive teaching block until the end of April, but from May it
becomes Priority. The Reusability and
On Sat, 2009-03-14 at 19:10 +1100, Mark Wassell wrote:
I am trying install a package using cabal-install however the package
requies an older version of QuickCheck and one of the required packages
requires the latest version:
$ cabal fetch Reactive
Resolving dependencies...
cabal.exe:
On Tue, 2009-03-10 at 23:55 +0300, Bulat Ziganshin wrote:
starting with 6.6, ForeignArray access is no-op, so we can just use
obvious Ptr operations (via Storable class) to get unboxed arrays fast
access. so, no more need for those special ByteArray# access operations
but Array library
On Fri, 2009-03-13 at 20:30 +0300, Bulat Ziganshin wrote:
Hello Don,
Friday, March 13, 2009, 8:08:57 PM, you wrote:
What is the reason why you have decided to use unpinned arrays
(ByteArray#) instead of pinned arrays (Foreign.Ptr)?
They prevent heap fragmentation (and in general are
On Mon, 2009-03-09 at 18:29 -0700, Alexander Dunlap wrote:
Thanks for all of the responses!
So let me see if my summary is accurate here:
- ByteString is for just that: strings of bytes, generally read off of
a disk. The Char8 version just interprets the Word8s as Chars but
doesn't do
On Sat, Mar 14, 2009 at 09:40, Duncan Coutts
duncan.cou...@worc.ox.ac.uk wrote:
A medium term solution here should involve letting packages specify that
some of their dependencies are private, ie nothing is re-exported and
thus there is no danger of clashes.
Is the long term solution to
On Sat, 2009-03-14 at 10:02 -0600, Denis Bueno wrote:
On Sat, Mar 14, 2009 at 09:40, Duncan Coutts
duncan.cou...@worc.ox.ac.uk wrote:
A medium term solution here should involve letting packages specify that
some of their dependencies are private, ie nothing is re-exported and
thus there is
Daniel Peebles ha scritto:
I have added UAProd-based Binary instances to my copy of the uvector
repo at http://patch-tag.com/publicrepos/pumpkin-uvector .
I can confirm that it works for me.
However I have now a memory problem with data decoding.
I need to serialize the Netflix Prize
grzegorz.chrupala:
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
I am using Data.Binary in a couple of projects, but I have found its stack
and memory usage very hard to control. Its very common that decoding a map
or list of non-trivial size uses up
On 14 Mar 2009, at 10:20, Ashley Yakeley wrote:
We will have a more up-to-date distribution when a new machine takes
over from the existing machine at Yale.
I don't know when anyone will have a new machine.
The contract with Yale for running the haskell.org machine is due for
its yearly
Hi Dan
On 14 Mar 2009, at 14:26, Dan Doel wrote:
On Saturday 14 March 2009 8:12:09 am Conor McBride wrote:
Rome wasn't burnt in a day.
Of course I want more than just numerical indexing (and I even
have a plan) but numeric constraints are so useful and have
so much of their own peculiar
Don Stewart-2 wrote:
Have you tried the latest release, which modified the Map and [a]
instances?
No, I'm working with 0.5. I'll give the new version a try. Thanks!
--
Grzegorz
--
View this message in context:
http://www.nabble.com/Alternative-to-Data.Binary-tp22512229p22514771.html
The main issue seems to be that although the semantics of UIO may be
arbitrary, Wallace's patch actually broke deserialization for any
production-based UArr, and I'm not sure the benefits are worthwhile
(loading a file someone else sent you) given that endianness is
already not taken into account
On Friday 13 March 2009, Cristiano Paris wrote:
2009/3/13 Marcin Kosiba marcin.kos...@gmail.com:
Hi,
I've already checked those out. I tried using your yield
implementation and while it works, I couldn't get it to work with the
state monad.
So while:
data RecPair a b =
I'm sorry, I didn't mean to imply otherwise.
I can see your point, but maybe it would be even more flexible in that
kind of situation to keep a separate UIO-like API that allows one to
explicitly request a particular size? For your large dataset, you
could specify the entire filesize (divided by
For the second case you might be able to come up with a commutative
hash-combiner function for and ||.
For the lambda-term situation, I can think of a couple ways to hash
that give what you want.
(1) Ignore variable names altogether while hashing; this gives you
what you want but has the
On Saturday 14 March 2009 1:07:01 pm Conor McBride wrote:
But this...
2) A family of singleton types int(n) parameterized by the static
type.
For instance, int(5) is the type that contains only the run-time
value 5.
3) An existential around the above family for representing
Don Stewart ha scritto:
grzegorz.chrupala:
Hi all,
Is there a serialization library other than the Data.Binary from hackage?
I am using Data.Binary in a couple of projects, but I have found its stack
and memory usage very hard to control. Its very common that decoding a map
or list of
Grzegorz Chrupala grzegorz.chrup...@computing.dcu.ie wrote:
Hi all,
Is there a serialization library other than the Data.Binary from
hackage?
There are Iteratees[1]. They're still grok-in-process___ community-wise
They are (afaik) currently only used for file input, though it's
certainly
Claus None of which is satisfactory. You might also want to add
Claus yourself to this ticket:
Clausindex out of range error message regression
Claus http://hackage.haskell.org/trac/ghc/ticket/2669
How do I do that?
Ghc Trac's idea of voting is by adding yourself to the cc, so
Can someone provide the induction-case proof of the following identity:
foldl (-) ((-) x y) ys = (foldl (-) x ys) - y
If foldl is defined as usual:
foldl :: (b - a - b) - b - [a] - b
foldl f e [] = e
foldl f e (x : xs) = myFoldl f (f e x) xs
The
Hello,
What's the current best practice to build shared objects / dlls to
call Haskell from C? I think I figured out the basics, but I would
like to understand the picture completely and document the current
state of affairs in the Haskell wiki. In particular, I'd like to make
sure that the
Hi Dan
On 14 Mar 2009, at 18:48, Dan Doel wrote:
On Saturday 14 March 2009 1:07:01 pm Conor McBride wrote:
I don't think the duplicate-or-plunge dilemma you
pose exhausts the options. At least, I seem no reason to presume
so and I look forward to finding out!
I didn't mean to suggest that
http://archhaskell.wordpress.com/2009/03/14/arch-haskell-news-mar-14-2009/
A regular update of Haskell in Arch Linux
Arch now has 974 Haskell packages in AUR. That’s 12 new packages this
week, and lots of updates as well.
See the blog for the full list of updates.
-- Don
At 8:45 PM + 3/14/09, R J wrote:
Can someone provide the induction-case proof of the following identity:
foldl (-) ((-) x y) ys = (foldl (-) x ys) - y
If foldl is defined as usual:
foldl :: (b - a - b) - b - [a] - b
foldl f e [] = e
foldl f e (x :
Am Samstag, 14. März 2009 21:45 schrieb R J:
Can someone provide the induction-case proof of the following identity:
foldl (-) ((-) x y) ys = (foldl (-) x ys) - y
If foldl is defined as usual:
foldl :: (b - a - b) - b - [a] - b
foldl f e [] = e
(R)
On Fri, 13 Mar 2009, Mark Spezzano wrote:
1. Don’t bother. Just use Integer.
2. Use the type
data Natural = Zero | Succ !Natural
3. Use the following definition taken from the Gentle Introduction to Haskell
98
newtype Natural = MakeNatural Integer
This option looks like non-negative
On Saturday 14 March 2009, Daniel Fischer wrote:
Am Samstag, 14. März 2009 21:45 schrieb R J:
Can someone provide the induction-case proof of the following identity:
foldl (-) ((-) x y) ys = (foldl (-) x ys) - y
If foldl is defined as usual:
foldl :: (b - a -
Colin Paul Adams wrote:
Adrian == Adrian Neumann aneum...@inf.fu-berlin.de writes:
Adrian You can use the ghci debugger
http://www.haskell.org/ghc/docs/latest/html/users_guide/ghci-
Adrian debugger.html
Adrian it can set breakpoints on exceptions.
So i tried adding the
Am Samstag, 14. März 2009 22:44 schrieb Marcin Kosiba:
(L) forall u v w. (u - v) - w = (u - v) - w
Typo? :)
(L) forall u v w. (u - v) - w = (u - w) - v
Sure. Thanks for spotting it.
I had (x-y)-z = (x-z)-y first, then decided it would be better to use
different variable names...
On Sat, 14 Mar 2009, Martijn van Steenbergen wrote:
Henning Thielemann wrote:
Of course, style is a matter of taste. So there are as many good styles as
programmers and there won't be an official style guide, I'm afraid.
While that is true, it's no valid reason to not have a style guide.
On Fri, 13 Mar 2009, Wolfgang Jeltsch wrote:
Am Freitag, 13. März 2009 09:21 schrieb Roman Cheplyaka:
* Alexander Dunlap alexander.dun...@gmail.com [2009-03-12 20:01:57-0700]
Also, a lot of functions just take
Integers so it would be more of a pain to use.
AFAIK there are very few
So, I tweaked Text.Regex to have the behavior I need.
http://patch-tag.com/repo/haskell-learning/browse/regexStuff/pcreReplace.hs
FWIW, the problem I was trying to solve was deleting single newlines
but not strings of newlines in a document. Dead simple for pcre-regex
with lookaround. But, I
On Sat, 14 Mar 2009, Peter Verswyvelen wrote:
I was using the transformers but still had to implement the Applicative
instance of State
This package contains an applicative instance for StateT but not for State
In 'transformers' State is a type synonym for StateT Identity and thus
does not
Also, consider stealing the regex susbt code from:
http://shootout.alioth.debian.org/u64q/benchmark.php?test=regexdnalang=ghcid=4
tphyahoo:
So, I tweaked Text.Regex to have the behavior I need.
http://patch-tag.com/repo/haskell-learning/browse/regexStuff/pcreReplace.hs
FWIW, the
On 2009 Mar 14, at 19:01, Thomas Hartman wrote:
FWIW, the problem I was trying to solve was deleting single newlines
but not strings of newlines in a document. Dead simple for pcre-regex
with lookaround. But, I think, impossible with posix regex.
s/(^|[^\n])\n($|[^\n])/\1\2/g;
POSIX regexen
Sittampalam, Ganesh wrote:
I think they have a useful place in propagating semi-global
configuration information without imposing huge syntactic overhead.
Right, for instance,
type MyMonad a = (?env :: Env) = IO a
No lift needed!
I was hoping to use IPs to do OO-style implicit type
Hi Roman,
So are you really talking about an equivalence relation on the
function's domain? The reason I ask is that it is well known that
f(a)=f(b) establishes an equivalence relation on f's co-domain!
Vasili
___
Haskell-Cafe mailing list
Mark Spezzano wrote:
Because Haskell is not OO, it is functional, I was wondering if there is
some kind of analogous “design pattern”/”template” type concept that
describe commonly used functions that can be “factored out” in a general
sense to provide the same kind of usefulness that Design
2009/3/15 Achim Schneider bars...@web.de
Hmmm. Output-iteratees are a very, very, interesting thing to think
about.
Careful, comments like that have a tendency to invoke Oleg. Next thing you know:
Interesting Question -- Maybe you could...
^ |
Hi!
I was trying to install hs-plugins both from sources $./Setup.lhs
... and with $cabal fetchcabal install and both failed.
It always reports that Linker.h is missing. I have tried to use
--extra-include-dirs with path to ghc-6.10.1 dir and
ghc-6.10.1/include dir. Nothing changed.
Here is a
wren:
There also a number of idioms which are similar in scope to the idioms
that arise in other languages: using tail recursion, accumulators,
continuation-passing transformations, closures over recursion[6],
Schwartzian transforms, etc.
[6] For lack of a better name. I mean doing
R J wrote:
2. I believe that the reverse implementation--namely, implementing
foldr in terms of foldl--is impossible. What's the proof of that?
As others have said, foldr in terms of foldl is impossible when infinite
lists are taken into account. For finite lists it's easy though:
(\f z
75 matches
Mail list logo