Re: Re[2]: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Luke Palmer
On Jan 10, 2008 1:36 PM, Bulat Ziganshin <[EMAIL PROTECTED]> wrote: > Hello Mark, > > Thursday, January 10, 2008, 4:25:20 PM, you wrote: > > "instance Num a => A a" > > > Mean the same thing as > > > "instance A (forall a.Num a=>a)" > > programmers going from OOP world always forget that classes in

Re: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Luke Palmer
On Jan 10, 2008 1:25 PM, Nicholls, Mark <[EMAIL PROTECTED]> wrote: > Thanks for your response, I think you helped me on one of my previous > abberations. > > Hmmmthis all slightly does my head inon one hand we have > typesthen type classes (which appear to be a relation defined on > typ

[Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Achim Schneider
Achim Schneider <[EMAIL PROTECTED]> wrote: > The surest thing to make people switch is to make them not aware of > it, i.e. make things look exactly like in C, with incremental updates > of the same variable and everything, while still retaining a purely > functional semantic under the hood. > >

[Haskell-cafe] Re: Why purely in haskell?

2008-01-10 Thread Niko Korhonen
Neil Mitchell wrote: Laziness and purity together help with equational reasoning, compiler transformations, less obscure bugs, better compositionality etc. Although it could be argued that laziness is the cause of some very obscure bugs... Niko

[Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Achim Schneider
"Sebastian Sylvan" <[EMAIL PROTECTED]> wrote: > > > > You make less bugs with that language? Fucking learn to write C++! > > Excuse me? > A probable exclamation of a pointy-haired boss, that is. What I wanted to say is that if you tell such a guy that you'll make less bugs in language X, he would

RE: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Nicholls, Mark
> > class A a > > type T = (forall x.Num x=>x) > > instance A T > > "type" declares a synonym, like #define in C - but working only on types. > So, essentially, you wrote Yep that's fine.. > > instance A (forall x.Num x => x) > Yep > > which is not very Haskelly. > Hmmm... > > > > I a

Re[2]: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Bulat Ziganshin
Hello Mark, Thursday, January 10, 2008, 4:25:20 PM, you wrote: "instance Num a =>> A a" > Mean the same thing as > "instance A (forall a.Num a=>a)" programmers going from OOP world always forget that classes in Haskell doesn't the same as classes in C++. *implementation* of this instance requi

Re: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Miguel Mitrofanov
> class A a > type T = (forall x.Num x=>x) > instance A T "type" declares a synonym, like #define in C - but working only on types. So, essentially, you wrote instance A (forall x.Num x => x) which is not very Haskelly. > I am simply trying to state that all members of typeclass Num are of > t

RE: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Nicholls, Mark
Thanks for your response, I think you helped me on one of my previous abberations. Hmmmthis all slightly does my head inon one hand we have typesthen type classes (which appear to be a relation defined on types)then existential types...which now appear not to be treated quite in th

Re: [Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Luke Palmer
On Jan 10, 2008 1:03 PM, Nicholls, Mark <[EMAIL PROTECTED]> wrote: > Should be straight forwardsimplest example is... > > class A a > > data D = D1 > > instance A D > > fine.D is declared to be a member of type class A > > what about. > > class A a > > type T = (forall x.Num x=>x) >

[Haskell-cafe] confusion about 'instance'....

2008-01-10 Thread Nicholls, Mark
Should be straight forwardsimplest example is... class A a data D = D1 instance A D fine.D is declared to be a member of type class A what about. class A a type T = (forall x.Num x=>x) instance A T error!... " Illegal polymorphic or qualified type: forall x. (Num x) => x

Re: [Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Sebastian Sylvan
On Jan 10, 2008 12:41 PM, Achim Schneider <[EMAIL PROTECTED]> wrote: > "Sebastian Sylvan" <[EMAIL PROTECTED]> wrote: > > > > > For those who don't know him, Tim Sweeney is the main programmer > > > > behind Epic Games's popular Unreal Engine. When he talks, many > > > > game developers will listen.

Re: [Haskell-cafe] viewing HS files in Firefox

2008-01-10 Thread Jules Bean
Johan Tibell wrote: Adding the following to my lighttpd config (on Ubuntu Feisty) solves the problem from the server side: external configuration files ## mimetype mapping # change mime type for haskell source files so they get displayed # inside the browser include_shell "/usr/share/light

Re: [Haskell-cafe] ANNOUNCE: Haddock version 2.0.0.0

2008-01-10 Thread David Waern
2008/1/10, Alfonso Acosta <[EMAIL PROTECTED]>: > On Jan 8, 2008 1:28 PM, David Waern <[EMAIL PROTECTED]> wrote: > > Dear Haskell community, > > > > I'm proud to announce the release of Haddock 2.0.0.0! > > Great! I already tested a dracs spanshot before the release and seemed > to work well with TH

[Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Achim Schneider
"Sebastian Sylvan" <[EMAIL PROTECTED]> wrote: > > > For those who don't know him, Tim Sweeney is the main programmer > > > behind Epic Games's popular Unreal Engine. When he talks, many > > > game developers will listen. > > > > > We will dream, most likely. > > > > > Perhaps more importantly, any

Re: [Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Sebastian Sylvan
On Jan 10, 2008 11:51 AM, Achim Schneider <[EMAIL PROTECTED]> wrote: > "Nick Rolfe" <[EMAIL PROTECTED]> wrote: > > > http://morpheus.cs.ucdavis.edu/papers/sweeny.pdf > > > > He refers to Haskell and its strengths (and some of its weaknesses) > > quite a bit. > > > > For those who don't know him, Ti

[Haskell-cafe] Re: Tim Sweeney (the gamer)

2008-01-10 Thread Achim Schneider
"Nick Rolfe" <[EMAIL PROTECTED]> wrote: > http://morpheus.cs.ucdavis.edu/papers/sweeny.pdf > > He refers to Haskell and its strengths (and some of its weaknesses) > quite a bit. > > For those who don't know him, Tim Sweeney is the main programmer > behind Epic Games's popular Unreal Engine. When

[Haskell-cafe] Displaying steps in my interpreter

2008-01-10 Thread Victor Nazarov
Hello, I have little practice in Haskell. And I look forward for suggestions on how to improve the code. Code is not working: some definitions are missed. The goal of the code is to implement the evaluator for untyped lambda-calculus. The main problem is how to display each step of reduction? More

Re: [Haskell-cafe] Tim Sweeney (the gamer)

2008-01-10 Thread Nick Rolfe
On 10/01/2008, Galchin Vasili <[EMAIL PROTECTED]> wrote: > Hello, > > I have been reading with great interested Tim Sweeney's slides on the > Next Generation Programming Language. Does anybody know his email address? Vasili is referring to these slides, which will probably interest many peopl

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Henning Thielemann
On Thu, 10 Jan 2008, Ketil Malde wrote: > > I think you mean that they cannot be bottom if you want > > to compare them for equality. Yes. > > See above. What is the precise term for describing this? Structural > equality? > > On the other hand, some bottoms are exceptions, you may be able to >

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Ketil Malde
"Yitzchak Gale" <[EMAIL PROTECTED]> writes: >> In the semantic domain there is one bottom. >> In Haskell there are many expressions that represent bottom. >> One cannot test those for equality. If we are being pedantic, I can define data Foo = Foo instance Eq Foo where _ == _ = True

Re: [Haskell-cafe] viewing HS files in Firefox

2008-01-10 Thread Johan Tibell
Adding the following to my lighttpd config (on Ubuntu Feisty) solves the problem from the server side: external configuration files ## mimetype mapping # change mime type for haskell source files so they get displayed # inside the browser include_shell "/usr/share/lighttpd/create-mime.assign

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Yitzchak Gale
I wrote: >> Like nearly all programming languages, Haskell implements >> the standard IEEE behavior for floating point numbers. >> That leads to some mathematical infelicities that are >> especially irking to us in Haskell, but the consensus was >> that it is best to follow the standard. Jules Bea

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Yitzchak Gale
Cristian Baboi wrote: > I think this should be put this way: > Bottom is a part of the semantic domain which is not Haskell. Rather, something outside Haskell that describes what Haskell programs mean. Yes. > In the semantic domain there is one bottom. > In Haskell there are many expressions that

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Yitzchak Gale
Cristian Baboi wrote: >>> and there is no such thing as "the same bottom" right ? I wrote: >> Yes and no. > Semantically, Yes and No is bottom ? Yes and no. -Yitz ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/li

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Jules Bean
Yitzchak Gale wrote: Mitar wrote: Why is 0/0 (which is NaN) > 1 == False and at the same time 0/0 < 1 == False. This means that 0/0 == 1? No, because also 0/0 == 1 == False. I understand that proper mathematical behavior would be that as 0/0 is mathematically undefined that 0/0 cannot be even co

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Cristian Baboi
On Thu, 10 Jan 2008 11:23:51 +0200, Yitzchak Gale <[EMAIL PROTECTED]> wrote: Cristian Baboi wrote: and there is no such thing as "the same bottom" right ? Yes and no. Semantically, Yes and No is bottom ? Information from NOD32 This message was checked by NOD32 Antiviru

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Yitzchak Gale
Cristian Baboi wrote: > and there is no such thing as "the same bottom" right ? Yes and no. Semantically, every bottom is the same. However, the Haskell Report makes bottom an explicit exceptional case. Compilers are allowed to do whatever they want with bottoms, including different results for di

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Cristian Baboi
and there is no such thing as "the same bottom" right ? On Thu, 10 Jan 2008 11:13:05 +0200, Ketil Malde <[EMAIL PROTECTED]> wrote: "Cristian Baboi" <[EMAIL PROTECTED]> writes: I think it's a bug. Here is why: let f = (\x -> x/0) in f 0 == f 0 Referential transparency say that f 0 must eq

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Yitzchak Gale
Mitar wrote: > > Why is 0/0 (which is NaN) > 1 == False and at the same time 0/0 < 1 == > > False. This means that 0/0 == 1? No, because also 0/0 == 1 == False. > > I understand that proper mathematical behavior would be that as 0/0 is > > mathematically undefined that 0/0 cannot be even compared t

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Cristian Baboi
On Thu, 10 Jan 2008 10:48:51 +0200, Benja Fallenstein <[EMAIL PROTECTED]> wrote: Hi Mitar, On Jan 10, 2008 9:22 AM, Mitar <[EMAIL PROTECTED]> wrote: I understand that proper mathematical behavior would be that as 0/0 is mathematically undefined that 0/0 cannot be even compared to 1. My und

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Ketil Malde
"Cristian Baboi" <[EMAIL PROTECTED]> writes: > I think it's a bug. > Here is why: > > let f = (\x -> x/0) in f 0 == f 0 > > Referential transparency say that f 0 must equal to f 0, but in this > case it is not. :-) I think you are wrong. Referential transparency says that you can replace any oc

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Cristian Baboi
On Thu, 10 Jan 2008 10:48:51 +0200, Benja Fallenstein <[EMAIL PROTECTED]> wrote: Hi Mitar, On Jan 10, 2008 9:22 AM, Mitar <[EMAIL PROTECTED]> wrote: I understand that proper mathematical behavior would be that as 0/0 is mathematically undefined that 0/0 cannot be even compared to 1. My und

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Benja Fallenstein
Hi Mitar, On Jan 10, 2008 9:22 AM, Mitar <[EMAIL PROTECTED]> wrote: > I understand that proper mathematical behavior would be that as 0/0 is > mathematically undefined that 0/0 cannot be even compared to 1. My understanding is that common mathematical practice is that comparing an undefined value

Re: [Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Cristian Baboi
On Thu, 10 Jan 2008 10:22:03 +0200, Mitar <[EMAIL PROTECTED]> wrote: Hi! Why is 0/0 (which is NaN) > 1 == False and at the same time 0/0 < 1 == False. This means that 0/0 == 1? No, because also 0/0 == 1 == False. I understand that proper mathematical behavior would be that as 0/0 is mathematic

[Haskell-cafe] 0/0 > 1 == False

2008-01-10 Thread Mitar
Hi! Why is 0/0 (which is NaN) > 1 == False and at the same time 0/0 < 1 == False. This means that 0/0 == 1? No, because also 0/0 == 1 == False. I understand that proper mathematical behavior would be that as 0/0 is mathematically undefined that 0/0 cannot be even compared to 1. There is probably

<    1   2