[Haskell-cafe] Real World Haskell Chapter 11 ... Testing

2008-10-11 Thread Galchin, Vasili
Hi, Testing of "pure" code ... . way cool ... I am sure there literature from the first order logic, model theory, categorical logic viewpoint?? Kind regards, Vasili ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mai

[Haskell-cafe] Re: How to translate Haskell to other languages?

2008-10-11 Thread mail
"Jason Dagit" <[EMAIL PROTECTED]> writes: > I don't recall if I mentioned this in my original email. My goal is to do > automatic > translations. So, no you can't partially apply zipWith, but then that's > because Python doesn't > support partial application. On the other hand, you can easily

Re: [Haskell-cafe] Shooting your self in the foot with Haskell

2008-10-11 Thread Simon Richard Clarkstone
John Van Enk wrote: On Sun, Oct 5, 2008 at 11:21 PM, John Van Enk <[EMAIL PROTECTED] > wrote: On Sun, Oct 5, 2008 at 6:22 PM, Simon Richard Clarkstone <[EMAIL PROTECTED] > wrote: BTW, these could go on the wiki. I'll see about putting them

[Haskell-cafe] Re: Ubuntu Haskell

2008-10-11 Thread Don Stewart
ashley: > Don Stewart wrote: > >* Arch now has 609 Haskell packages in AUR. > > Have you thought about doing this for Ubuntu? If you know how to > automatically generate packages, you could set up a PPA (private package > archive) on Launchpad. I've spoken with Jeremy Shaw, who has similar

[Haskell-cafe] Ubuntu Haskell

2008-10-11 Thread Ashley Yakeley
Don Stewart wrote: * Arch now has 609 Haskell packages in AUR. Have you thought about doing this for Ubuntu? If you know how to automatically generate packages, you could set up a PPA (private package archive) on Launchpad. -- Ashley Yakeley _

Re: [Haskell-cafe] [] vs [()]

2008-10-11 Thread Simon Richard Clarkstone
Sam Danielson wrote: The [] constructor takes no arguments and is like Nothing in the Maybe type. The list ":" (cons) infix constructor takes two arguments, an element of type a and a list of type a, to construct a new list. Compare to Maybe. data []a = [] | a : [a] data

[Haskell-cafe] Congrats. to wxHaskell

2008-10-11 Thread Don Stewart
I just want to congratulate the wxHaskell team on their new release. With GHC 6.10 RC, cabal 1.6, and cabal-install 0.6, I was able to simply, cabal install wxcore wx And it all worked. Well done! -- Don ___ Haskell-Cafe mailing list Haskell-Cafe

Re: [Haskell-cafe] OT: Haskell desktop wallpaper?

2008-10-11 Thread Albert Y. C. Lai
Magnus Therning wrote: Where can I find some nice wallpapers inspired by Haskell, or maybe even created by Haskell code? I once suggested a futuristic feature for xmonad or xmonad plugin: screensaver that randomly picks a haskell lecture video to play or a haskell tutorial page to display. Th

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Justin Bailey
On Sat, Oct 11, 2008 at 5:30 AM, Holger Siegel <[EMAIL PROTECTED]> wrote: > > - The explanation of the layout rule is wrong. If you define more than one > value in a let declaration, then it is only required that the identifiers > start on the same column. Thank you - updated. > > - When I starte

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Justin Bailey
Thanks to everyone for their feedback. I've made some updates and posted the PDF to my blog: http://blog.codeslower.com/2008/10/The-Haskell-Cheatsheet On Sat, Oct 11, 2008 at 4:33 AM, Thomas Hartman <[EMAIL PROTECTED]> wrote: > Very nice! > > I have my own cheat list, which are haskell commands

Re: [Haskell-cafe] How to translate Haskell to other languages?

2008-10-11 Thread David Menendez
2008/10/11 Jason Dagit <[EMAIL PROTECTED]>: > > On Sat, Oct 11, 2008 at 8:55 AM, Matthew Naylor > <[EMAIL PROTECTED]> wrote: >> Here is the result of (manually) applying D to the list-reversing program. > > If nil() corresponds to [] in Haskell, then how did you arrive at this > definition? As De

Re: [Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread Andrew Coppin
apfelmus wrote: ... and a solution to a problem that you souldn't have in the first place. I mean, if you want to construct XML or SQL statements, you ought to use an abstract data type that ensures proper nesting etc. and not a simple string. Right. And if you have 25 KB of HTML data, you'r

Re: [Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread Andrew Coppin
Svein Ove Aas wrote: On Sat, Oct 11, 2008 at 9:30 PM, Iain Barnett <[EMAIL PROTECTED]> wrote: Personally, I use stored procedures with a database as they protect from sql injection attacks (unless you write some really stupid procedures). Isn't this what parametrized queries are for?

Re: [Haskell-cafe] How to translate Haskell to other languages?

2008-10-11 Thread Jason Dagit
On Sat, Oct 11, 2008 at 8:55 AM, Matthew Naylor < [EMAIL PROTECTED]> wrote: > Hi Jason, > > I don't know Python, but let me share some thoughts that you might > find useful. > > First, a few questions about your manual translations. Are your > functions curried? For example, can I partially appl

Re: [Haskell-cafe] Constraints at construction

2008-10-11 Thread Bit Connor
On Thu, Oct 9, 2008 at 3:05 PM, Mitchell, Neil <[EMAIL PROTECTED]> wrote: > Hi Iain, > > The wiki page has quite a nice article: > http://www.haskell.org/haskellwiki/Smart_constructors Smart constructors are nice but if your module doesn't also export the regular constructor then you can't pattern

Re: [Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread Iain Barnett
On 11 Oct 2008, at 9:02 pm, Svein Ove Aas wrote: On Sat, Oct 11, 2008 at 9:30 PM, Iain Barnett <[EMAIL PROTECTED]> wrote: Personally, I use stored procedures with a database as they protect from sql injection attacks (unless you write some really stupid procedures). Isn't this what para

Re: [Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread Svein Ove Aas
On Sat, Oct 11, 2008 at 9:30 PM, Iain Barnett <[EMAIL PROTECTED]> wrote: > > Personally, I use stored procedures with a database as they protect from sql > injection attacks (unless you write some really stupid procedures). > Isn't this what parametrized queries are for? ___

Re: [Haskell-cafe] Constraints at construction

2008-10-11 Thread Jake McArthur
On Oct 11, 2008, at 2:54 PM, Bit Connor wrote: Smart constructors are nice but if your module doesn't also export the regular constructor then you can't pattern match against it. It would be cool if there was a way to export constructors from a module, but only for use in pattern matching and

Re: [Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread Iain Barnett
On 11 Oct 2008, at 6:34 pm, apfelmus wrote: Andrew Coppin wrote: Martin DeMello wrote: http://blog.moertel.com/articles/2006/10/18/a-type-based-solution- to-the-strings-problem is a brilliant example of a common workaday problem found in other languages, and solved elegantly in Haskell O

Re: [Haskell-cafe] Haskell on the JVM

2008-10-11 Thread Sean Leather
> > Are there, or have there been Haskell ports to the JVM? Are any of them > alive and well? > See the thread started 9 September on "Haskell and Java": http://thread.gmane.org/gmane.comp.lang.haskell.cafe/44252 Sean ___ Haskell-Cafe mailing list Has

Re: [Haskell-cafe] How to translate Haskell to other languages?

2008-10-11 Thread Derek Elkins
On Sat, 2008-10-11 at 16:55 +0100, Matthew Naylor wrote: > Hi Jason, > > I don't know Python, but let me share some thoughts that you might > find useful. > > First, a few questions about your manual translations. Are your > functions curried? For example, can I partially apply zipWith? Also,

[Haskell-cafe] Re: Interesting new user perspective

2008-10-11 Thread apfelmus
Andrew Coppin wrote: > Martin DeMello wrote: >> http://blog.moertel.com/articles/2006/10/18/a-type-based-solution-to-the-strings-problem >> >> is a brilliant example of a common workaday problem found in other >> languages, and solved elegantly in Haskell >> > > Oh, hey, that's pretty nice...

Re: [Haskell-cafe] Haskell on the JVM

2008-10-11 Thread John A. De Goes
There's a YHC that can compile to JavaScript, and JavaScript can be run on Java... Which means, practically speaking, there is no YHC backend for the JVM. Regards, John A. De Goes N-BRAIN, Inc. http://www.n-brain.net [n minds are better than n-1] On Oct 11, 2008, at 11:08 AM, Brandon S. Al

Re: [Haskell-cafe] Haskell on the JVM

2008-10-11 Thread Brandon S. Allbery KF8NH
On 2008 Oct 11, at 12:07, David Leimbach wrote: Are there, or have there been Haskell ports to the JVM? Are any of them alive and well? YHC, last I heard, was alive and well and there's a YHC Core backend for the JVM. Is there an interest in hosting GHC on the JVM (besides my own). The

Re: [Haskell-cafe] Haskell on the JVM

2008-10-11 Thread John A. De Goes
LamdaVM was the only full-fledged effort to port Haskell to the JVM, and like most graduate school projects, the project is now dead. I have strong interest in hosting GHC on the JVM. And I suspect it would be good for the Haskell community, as the JVM already runs on nearly every machine

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Stephen Hicks
On Fri, Oct 10, 2008 at 7:08 PM, Justin Bailey <[EMAIL PROTECTED]> wrote: > I've created a "cheat sheet" for Haskell. It's a PDF that tries to > summarize Haskell 98's syntax, keywords and other language elements. > It's currently available on hackage[1]. Once downloaded, unpack the > archive and y

[Haskell-cafe] Haskell on the JVM

2008-10-11 Thread David Leimbach
Are there, or have there been Haskell ports to the JVM? Are any of them alive and well? Is there an interest in hosting GHC on the JVM (besides my own). I know I don't have time to tackle such a project but I'd be extremely interested in using such a thing. Especially in my day to day work. I c

Re: [Haskell-cafe] How to translate Haskell to other languages?

2008-10-11 Thread Matthew Naylor
Hi Jason, I don't know Python, but let me share some thoughts that you might find useful. First, a few questions about your manual translations. Are your functions curried? For example, can I partially apply zipWith? Also, you put a "thunk" around things like "cons(...)" --- should it not be t

Re: [Haskell-cafe] External Sort and unsafeInterleaveIO

2008-10-11 Thread Thomas Hartman
I kinda-sorta half-cabalized it at darcs get http://darcsdump.dreamhosters.com/external-sort (untested via cabal install but mostly done) As soon as my project gets approved I'll put it up on hackage. If Ben wants it under his account at hackage of course I'll defer to him. Thomas. 2007/7/18 D

Re: [Haskell-cafe] Haskell in Artificial Intelligence

2008-10-11 Thread Chryssochoidis Christos
On 11 Οκτ 2008, at 11:41 ΠΜ, Bartosz Wójcik wrote: Hi CC, you can find a word about possible usage of functional programming in AI in following paper: http://www.cs.chalmers.se/~rjmh/Papers/whyfp.html . Besides in HackageDB you can find separate category AI. I had pleasure also to write an

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Dino Morelli
On Fri, 10 Oct 2008, Justin Bailey wrote: I've created a "cheat sheet" for Haskell. It's a PDF that tries to summarize Haskell 98's syntax, keywords and other language elements. It's currently available on hackage[1]. Once downloaded, unpack the archive and you'll see the PDF. A literate source

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Holger Siegel
On Saturday 11 October 2008 01:08:15 Justin Bailey wrote: > This is a beta release (which is why I've limited the audience by > using hackage) to get feedback before distributing the PDF to a wider > audience. With that in mind, I welcome your comments or patches[2]. > > Justin > > [1] http://hack

Re: [Haskell-cafe] [ANN] Haskell Cheatsheet v1.0

2008-10-11 Thread Thomas Hartman
Very nice! I have my own cheat list, which are haskell commands I find useful but find inconvenient or difficult to look up in the supplied documentation. I actually hardwire my cheats into .bashrc doing something like thartman_haskell_cheatting() { cat << EOF blah blah cheat } so i can quic

Re: [Haskell-cafe] Interesting new user perspective

2008-10-11 Thread Ryan Ingram
If you want quick examples of idiomatic haskell including stdin/stdout I/O, I like this page: http://www.haskell.org/haskellwiki/Simple_unix_tools -- ryan On Fri, Oct 10, 2008 at 7:08 PM, Iain Barnett <[EMAIL PROTECTED]> wrote: > On 9 Oct 2008, at 9:33 pm, Andrew Coppin wrote: > >> I think

Re: [Haskell-cafe] Haskell in Artificial Intelligence

2008-10-11 Thread Bartosz Wójcik
Hi CC, you can find a word about possible usage of functional programming in AI in following paper: http://www.cs.chalmers.se/~rjmh/Papers/whyfp.html . Besides in HackageDB you can find separate category AI. I had pleasure also to write an AI of simple game (http://en.wikipedia.org/wiki/Paper_So

Re: [Haskell-cafe] Haskell in Artificial Intelligence

2008-10-11 Thread Chryssochoidis Christos
On 11 Οκτ 2008, at 10:57 ΠΜ, Krasimir Angelov wrote: Hi Christos We use Haskell for natural language processing. See here: http://www.cs.chalmers.se/~aarne/GF/ Best regards, Krasimir Thank you very much for your response Krasimir. Best regards, Christos On Fri, Oct 10, 2008 at 8:45

[Haskell-cafe] How to translate Haskell to other languages?

2008-10-11 Thread Jason Dagit
Hello, I was thinking about translating Haskell to other languages, python being the main one at the moment. Here is my attempt at manually encoding Haskell in Python: \begin{code} import types class thunk: '''Thunks allow us to delay a computation and they also store their value insi