Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-17 Thread Douglas Brebner
On 17/02/2011 18:08, Eliot Miranda wrote: On Thu, Feb 17, 2011 at 1:59 AM, Douglas Brebner mailto:squeakli...@fang.demon.co.uk>> wrote: On 16/02/2011 20:13, Eliot Miranda wrote: On Wed, Feb 16, 2011 at 12:04 PM, Stéphane Ducasse mailto:stephane.duca...@inria.fr>> wrote:

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-17 Thread Eliot Miranda
On Thu, Feb 17, 2011 at 1:59 AM, Douglas Brebner < squeakli...@fang.demon.co.uk> wrote: > On 16/02/2011 20:13, Eliot Miranda wrote: > > > > On Wed, Feb 16, 2011 at 12:04 PM, Stéphane Ducasse < > stephane.duca...@inria.fr> wrote: > >> >> On Feb 16, 2011, at 6:15 PM, Eliot Miranda wrote: >> >> > >>

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-17 Thread Douglas Brebner
On 16/02/2011 20:13, Eliot Miranda wrote: On Wed, Feb 16, 2011 at 12:04 PM, Stéphane Ducasse mailto:stephane.duca...@inria.fr>> wrote: On Feb 16, 2011, at 6:15 PM, Eliot Miranda wrote: > > > On Tue, Feb 15, 2011 at 11:50 PM, Stéphane Ducasse mailto:stephane.duca...@inri

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Igor Stasenko
On 17 February 2011 01:28, Nicolas Cellier wrote: > 2011/2/17 Igor Stasenko : >> On 17 February 2011 00:51, Nicolas Cellier >> wrote: >>> 2011/2/17 Igor Stasenko : On 16 February 2011 22:00, Stéphane Ducasse wrote: > Ok this is my last mail on that topic. > apparentl

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Nicolas Cellier
2011/2/17 Igor Stasenko : > On 17 February 2011 00:51, Nicolas Cellier > wrote: >> 2011/2/17 Igor Stasenko : >>> On 16 February 2011 22:00, Stéphane Ducasse >>> wrote: Ok this is my last mail on that topic. >>> >>> apparently not ;) >>> > yes now do not think that I'm implying

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Igor Stasenko
On 17 February 2011 00:51, Nicolas Cellier wrote: > 2011/2/17 Igor Stasenko : >> On 16 February 2011 22:00, Stéphane Ducasse >> wrote: >>> Ok this is my last mail on that topic. >>> >> >> apparently not ;) >> >>> yes now do not think that I'm implying that you are not able to implement >>>

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Nicolas Cellier
2011/2/17 Igor Stasenko : > On 16 February 2011 22:00, Stéphane Ducasse wrote: >> Ok this is my last mail on that topic. >> > > apparently not ;) > >> >>> yes now do not think that I'm implying that you are not able to implement a >>> decompiler. >>> Now we have something else to do that dealing

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Igor Stasenko
On 16 February 2011 22:00, Stéphane Ducasse wrote: > Ok this is my last mail on that topic. > apparently not ;) > >> yes now do not think that I'm implying that you are not able to implement a >> decompiler. >> Now we have something else to do that dealing with the optimisation of a >> stupid

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Igor Stasenko
On 16 February 2011 21:59, Marcus Denker wrote: > > On Feb 16, 2011, at 12:57 PM, Stéphane Ducasse wrote: > >> >>> >>> On Wed, Feb 16, 2011 at 12:31 PM, Stéphane Ducasse >>> wrote: >>> yes now do not think that I'm implying that you are not able to implement a >>> decompiler. >>> Now we have so

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
On Feb 16, 2011, at 10:19 PM, Benoit St-Jean wrote: > A quick comment... > > This whole thing/discussion/war reminds me of the Squeak mailing list, long > ago, in its worst days... Let's all take a deep breath for a second and put > things in perspective : aren't we just talking about 2 (TWO)

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Benoit St-Jean
A quick comment... This whole thing/discussion/war reminds me of the Squeak mailing list, long ago, in its worst days... Let's all take a deep breath for a second and put things in perspective : aren't we just talking about 2 (TWO) methods here? Is this a do-it-now-or-die type of decision?

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
Ok this is my last mail on that topic. > yes now do not think that I'm implying that you are not able to implement a > decompiler. > Now we have something else to do that dealing with the optimisation of a > stupid method. > This is all my point. > Let us focus on the real problems. eliot is cr

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Marcus Denker
On Feb 16, 2011, at 12:57 PM, Stéphane Ducasse wrote: > >> >> On Wed, Feb 16, 2011 at 12:31 PM, Stéphane Ducasse >> wrote: >> yes now do not think that I'm implying that you are not able to implement a >> decompiler. >> Now we have something else to do that dealing with the optimisation of a

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
> > On Wed, Feb 16, 2011 at 12:31 PM, Stéphane Ducasse > wrote: > yes now do not think that I'm implying that you are not able to implement a > decompiler. > Now we have something else to do that dealing with the optimisation of a > stupid method. > This is all my point. > Let us focus on the

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Eliot Miranda
On Wed, Feb 16, 2011 at 12:31 PM, Stéphane Ducasse < stephane.duca...@inria.fr> wrote: > yes now do not think that I'm implying that you are not able to implement a > decompiler. > Now we have something else to do that dealing with the optimisation of a > stupid method. > This is all my point. > L

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
yes now do not think that I'm implying that you are not able to implement a decompiler. Now we have something else to do that dealing with the optimisation of a stupid method. This is all my point. Let us focus on the real problems. eliot is crying for caseOf: but we have 3 users. Stef On Fe

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Marcus Denker
Hi, What about postponing this dicussion to the week of the 7th of march? This will be far easier... (and I really did not have the energy to follow this discussion. Most of the emails in this thread I did not read). Marcus On Feb 16, 2011, at 12:12 PM, Stéphane Ducasse wrote: > > On

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Eliot Miranda
On Wed, Feb 16, 2011 at 12:04 PM, Stéphane Ducasse < stephane.duca...@inria.fr> wrote: > > On Feb 16, 2011, at 6:15 PM, Eliot Miranda wrote: > > > > > > > On Tue, Feb 15, 2011 at 11:50 PM, Stéphane Ducasse < > stephane.duca...@inria.fr> wrote: > > Eliot a final question. > > So how will you handle

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
Igor my point is how can we migrate from the old compiler to the new one that will probably not support inlining of caseOf: if we rely or have caseOf: in the old compiler. If we do not need case of inlining then we can remove it and we can also clean Object. Stef On Feb 16, 2011, at 6:42 PM,

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
On Feb 16, 2011, at 6:12 PM, Eliot Miranda wrote: > > > On Tue, Feb 15, 2011 at 11:17 PM, Stéphane Ducasse > wrote: > But it looks like a DSL to me. > > No its not. caseOf: is valid Smalltalk. It is another control structure > defined in the library rather than by the language, just like

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Stéphane Ducasse
On Feb 16, 2011, at 6:15 PM, Eliot Miranda wrote: > > > On Tue, Feb 15, 2011 at 11:50 PM, Stéphane Ducasse > wrote: > Eliot a final question. > So how will you handle OPAL compiler change in Cog? > Do you require that marcus and jorge have to deal with decompiler of caseOf: > in addition to

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Igor Stasenko
On 16 February 2011 18:15, Eliot Miranda wrote: > > > On Tue, Feb 15, 2011 at 11:50 PM, Stéphane Ducasse > wrote: >> >> Eliot a final question. >> So how will you handle OPAL compiler change in Cog? >> Do you require that marcus and jorge have to deal with decompiler of >> caseOf: in addition to

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-16 Thread Eliot Miranda
On Tue, Feb 15, 2011 at 11:50 PM, Stéphane Ducasse < stephane.duca...@inria.fr> wrote: > Eliot a final question. > So how will you handle OPAL compiler change in Cog? > Do you require that marcus and jorge have to deal with decompiler of > caseOf: in addition to all the rest? > Is it a strong requ

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
Eliot a final question. So how will you handle OPAL compiler change in Cog? Do you require that marcus and jorge have to deal with decompiler of caseOf: in addition to all the rest? Is it a strong requirement? Because then this is clear that Opal will be delayed. But may be it is not that importa

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
n > A standpoint is an intellectual horizon of radius zero. > (Albert Einstein) > > > From: Eliot Miranda > To: Pharo-project@lists.gforge.inria.fr > Sent: Tue, February 15, 2011 3:56:11 PM > Subject: Re: [Pharo-project] could we agree to remove caseOf: and > case

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
n of radius zero. > (Albert Einstein) > > > From: Eliot Miranda > To: Pharo-project@lists.gforge.inria.fr > Sent: Tue, February 15, 2011 3:56:11 PM > Subject: Re: [Pharo-project] could we agree to remove caseOf: and > caseOf:otherwise: > &g

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Nicolas Cellier
2011/2/15 Eliot Miranda : > > > On Tue, Feb 15, 2011 at 1:10 PM, Nicolas Cellier > wrote: >> >> 2011/2/15 Eliot Miranda : >> > >> > >> > On Tue, Feb 15, 2011 at 12:39 PM, Stéphane Ducasse >> > wrote: >> >> >> >> Eliot >> >> >> >> I can understand that well. Now we could just let this code in VMMa

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Benoit St-Jean
uary 15, 2011 3:56:11 PM Subject: Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise: On Tue, Feb 15, 2011 at 12:39 PM, Stéphane Ducasse wrote: Eliot > >I can understand that well. Now we could just let this code in VMMaker and not >inlining. >We fix 8 users

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Eliot Miranda
On Tue, Feb 15, 2011 at 1:10 PM, Nicolas Cellier < nicolas.cellier.aka.n...@gmail.com> wrote: > 2011/2/15 Eliot Miranda : > > > > > > On Tue, Feb 15, 2011 at 12:39 PM, Stéphane Ducasse > > wrote: > >> > >> Eliot > >> > >> I can understand that well. Now we could just let this code in VMMaker > an

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Nicolas Cellier
2011/2/15 Eliot Miranda : > > > On Tue, Feb 15, 2011 at 12:39 PM, Stéphane Ducasse > wrote: >> >> Eliot >> >> I can understand that well. Now we could just let this code in VMMaker and >> not inlining. >> We fix 8 users and we are done. I have concerned that we have a complex >> solution because i

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Casimiro de Almeida Barreto
Em 15-02-2011 16:55, Schwab,Wilhelm K escreveu: > I am not completely certain who is on which side here anymore, other than > #caseOf: is at the center of it. I think I saw Eliot say that Cog uses it; > if I got that right, it's a pretty compelling reason to keep it in the image. > Doing that,

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Nicolas Cellier
2011/2/15 Eliot Miranda : > > > On Tue, Feb 15, 2011 at 11:18 AM, Igor Stasenko wrote: >> >> On 15 February 2011 19:59, Eliot Miranda wrote: >> > >> > >> > On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse >> > wrote: >> >> >> >> Eliot >> >> >> >> you use caseOf: for the generation of C in Slan

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Eliot Miranda
On Tue, Feb 15, 2011 at 12:39 PM, Stéphane Ducasse < stephane.duca...@inria.fr> wrote: > Eliot > > I can understand that well. Now we could just let this code in VMMaker and > not inlining. > We fix 8 users and we are done. I have concerned that we have a complex > solution because it is complex >

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
Eliot I can understand that well. Now we could just let this code in VMMaker and not inlining. We fix 8 users and we are done. I have concerned that we have a complex solution because it is complex for a couple of use case. Of course we can do nothing (and we will probably not do it now) but

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 20:58, Eliot Miranda wrote: > > > On Tue, Feb 15, 2011 at 11:18 AM, Igor Stasenko wrote: >> >> On 15 February 2011 19:59, Eliot Miranda wrote: >> > >> > >> > On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse >> > wrote: >> >> >> >> Eliot >> >> >> >> you use caseOf: for the

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 20:38, wrote: > Em 15/02/2011 17:03, Igor Stasenko < siguc...@gmail.com > escreveu: > On 15 February 2011 19:23, wrote: > >> > Em 13/02/2011 21:21,  Stephen Taylor < stephen.tay...@bom.gov.au > >> > escreveu: Igor Stasenko wrote: >> > >> >> >> >> >> You have  some integers: 0

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Eliot Miranda
On Tue, Feb 15, 2011 at 11:18 AM, Igor Stasenko wrote: > On 15 February 2011 19:59, Eliot Miranda wrote: > > > > > > On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse > > wrote: > >> > >> Eliot > >> > >> you use caseOf: for the generation of C in Slang and VM maker. > >> Now this means that >

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread csrabak
Em 15/02/2011 17:03, Igor Stasenko < siguc...@gmail.com > escreveu: On 15 February 2011 19:23, wrote: > > Em 13/02/2011 21:21, Stephen Taylor < stephen.tay...@bom.gov.au > > > escreveu: Igor Stasenko wrote: > > > >> > >> >> You have some integers: 0 83 67 77 68 72 80 112 113 87 70 > >> >> 82

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 20:15, wrote: > Em 15/02/2011 10:37, Igor Stasenko < siguc...@gmail.com > escreveu: > > Whereas I understand we are community of spirited and humorous programmers, I > think that statements like: > >> I  agree.    Then  probably,  Pharo  should  move   it  to  separate >> 'Cr

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
On Feb 15, 2011, at 7:59 PM, Eliot Miranda wrote: > > > On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse > wrote: > Eliot > > you use caseOf: for the generation of C in Slang and VM maker. > Now this means that >- it does not need to be inlined > > No. If it is not inlined the si

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 19:59, Eliot Miranda wrote: > > > On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse > wrote: >> >> Eliot >> >> you use caseOf: for the generation of C in Slang and VM maker. >> Now this means that >>        - it does not need to be inlined > > No.  If it is not inlined the si

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread csrabak
Em 15/02/2011 10:37, Igor Stasenko < siguc...@gmail.com > escreveu: Whereas I understand we are community of spirited and humorous programmers, I think that statements like: > I agree.Then probably, Pharo should move it to separate > 'Crap-compat' package. Are not amenable to the "

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 19:23, wrote: > Em 13/02/2011 21:21, Stephen Taylor < stephen.tay...@bom.gov.au > escreveu: > Igor Stasenko wrote: > >> >> >> You  have some  integers: 0  83 67  77  68 72  80 112  113 87  70 >> >> 82. When a variable's value is equal to any of these... >> >> > Don't try to co

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Eliot Miranda
On Mon, Feb 14, 2011 at 11:00 PM, Stéphane Ducasse < stephane.duca...@inria.fr> wrote: > Eliot > > you use caseOf: for the generation of C in Slang and VM maker. > Now this means that >- it does not need to be inlined > No. If it is not inlined the simulator will go *much* slower. e.g.

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Schwab,Wilhelm K
e.inria.fr] On Behalf Of csra...@bol.com.br [csra...@bol.com.br] Sent: Tuesday, February 15, 2011 1:23 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise: Em 13/02/2011 21:21, Stephen Taylor < stephen.tay...@bom.gov.

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread csrabak
Adrien, Case (a.k.a "switch") constructs are not "so bad in Smalltalk" only, they are considered bad OO practice and it is tabled in the "The Object-Orientation Abuse" code smell when refactoring. there is an abundant literature about it that you can find online, so I'll refrain to make this p

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread csrabak
@lists.gforge.inria.fr] On Behalf Of Stephen Taylor [stephen.tay...@bom.gov.au] Sent: Sunday, February 13, 2011 6:21 PM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise: Igor Stasenko wrote: >> You have some inte

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread csrabak
Em 13/02/2011 21:21, Stephen Taylor < stephen.tay...@bom.gov.au > escreveu: Igor Stasenko wrote: > > >> You have some integers: 0 83 67 77 68 72 80 112 113 87 70 > >> 82. When a variable's value is equal to any of these... > > > Don't try to convince me that there are sort of problems whic

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Nicolas Cellier
2011/2/15 Igor Stasenko : > On 15 February 2011 12:50, David T. Lewis wrote: >> On Tue, Feb 15, 2011 at 08:00:18AM +0100, St?phane Ducasse wrote: >>> Eliot >>> >>> you use caseOf: for the generation of C in Slang and VM maker. >>> Now this means that >>>       - it does not need to be inlined >>>

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
>>> you use caseOf: for the generation of C in Slang and VM maker. >>> Now this means that >>> - it does not need to be inlined >>> - it could be packaged with VMMaker >>> >>> Are these two points correct? >> >> No. ? Apparently igor is just saying the contrary. You probably say no f

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Igor Stasenko
On 15 February 2011 12:50, David T. Lewis wrote: > On Tue, Feb 15, 2011 at 08:00:18AM +0100, St?phane Ducasse wrote: >> Eliot >> >> you use caseOf: for the generation of C in Slang and VM maker. >> Now this means that >>       - it does not need to be inlined >>       - it could be packaged with V

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread David T. Lewis
On Tue, Feb 15, 2011 at 08:00:18AM +0100, St?phane Ducasse wrote: > Eliot > > you use caseOf: for the generation of C in Slang and VM maker. > Now this means that > - it does not need to be inlined > - it could be packaged with VMMaker > > Are these two points correct? No. VMMaker

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
Eliot you use caseOf: for the generation of C in Slang and VM maker. Now this means that - it does not need to be inlined - it could be packaged with VMMaker Are these two points correct? Stef

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
you should follow my lecture if one day they let me do it at Lille. Why Boolean operations are not using ifTrue:ifFalse: everywhere? I spent two hours explaining that point. Stef On Feb 14, 2011, at 11:33 PM, Adrien BARREAU wrote: > Hi, > > I'm sorry to interrupt that discussion, but I read

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-15 Thread Stéphane Ducasse
> > > On Fri, Feb 11, 2011 at 1:43 PM, stephane ducasse > wrote: > Hi guys > > let us do another pass at cleaning and realigning the system. > Could we agree to deprecate caseOf: and caseOf:otherwise:? > it will simply the compiler, decompiler and also we do not need that at all. > > | z | z

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Igor Stasenko
On 14 February 2011 23:33, Adrien BARREAU wrote: > Hi, > > I'm sorry to interrupt that discussion, but I read all the messages about > that subject since you started to discuss it and I really would like to > understand a thing: > Why does the case structure seem to be so bad in Smalltalk? > > I h

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Adrien BARREAU
Hi, I'm sorry to interrupt that discussion, but I read all the messages about that subject since you started to discuss it and I really would like to understand a thing: Why does the case structure seem to be so bad in Smalltalk? I hope some of you could explain me :) Adrien.

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Stephen Taylor
Igor Stasenko wrote: On 14 February 2011 01:32, Schwab,Wilhelm K wrote: That's where I typically use a dictionary. Indeed. Yes - sensible answer from Wilhelm Schwab. You didn't answer the question though. Because it sounds rhetoric to me. How to deal with randomly put integers coming

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Eliot Miranda
On Mon, Feb 14, 2011 at 1:58 PM, Igor Stasenko wrote: > On 14 February 2011 22:38, Eliot Miranda wrote: > > > > > > On Fri, Feb 11, 2011 at 1:43 PM, stephane ducasse < > stephane.duca...@free.fr> > > wrote: > >> > >> Hi guys > >> > >> let us do another pass at cleaning and realigning the system.

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Igor Stasenko
On 14 February 2011 22:38, Eliot Miranda wrote: > > > On Fri, Feb 11, 2011 at 1:43 PM, stephane ducasse > wrote: >> >> Hi guys >> >> let us do another pass at cleaning and realigning the system. >> Could we agree to deprecate caseOf: and caseOf:otherwise:? >> it will simply the compiler, decompil

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Eliot Miranda
On Fri, Feb 11, 2011 at 1:43 PM, stephane ducasse wrote: > Hi guys > > let us do another pass at cleaning and realigning the system. > Could we agree to deprecate caseOf: and caseOf:otherwise:? > it will simply the compiler, decompiler and also we do not need that at > all. > > | z | z := {[#a]->[

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Stéphane Ducasse
> Yes, I myself find the implementation hackish, but I wish I could see > more pragmatic analysis based on exact usage of this message. > The discussion isn't going forward, every one camping on its position. > 1) Where is the message used ? > 2) How would you refactor the senders ? > 3) Does spe

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Igor Stasenko
On 14 February 2011 15:57, Henrik Sperre Johansen wrote: > > I agree with both Igor and Levente. > > Uses of caseOf: is often times solvable in more "elegant" ways. > > Though, I think in f.ex. HandMorph>>#processEvents  and > UTF8TextConverter>>nextFromStream:, it would actually *improve* readabi

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Henrik Sperre Johansen
I agree with both Igor and Levente. Uses of caseOf: is often times solvable in more "elegant" ways. Though, I think in f.ex. HandMorph>>#processEvents and UTF8TextConverter>>nextFromStream:, it would actually *improve* readability to use it. Got any good refactoring to symbolics for those two,

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-14 Thread Igor Stasenko
Of Stephen Taylor > [stephen.tay...@bom.gov.au] > Sent: Sunday, February 13, 2011 6:21 PM > To: Pharo-project@lists.gforge.inria.fr > Subject: Re: [Pharo-project] could we agree to remove caseOf:   and     > caseOf:otherwise: > > Igor Stasenko wrote: > >>> You have

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Schwab,Wilhelm K
ia.fr Subject: Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise: Igor Stasenko wrote: >> You have some integers: 0 83 67 77 68 72 80 112 113 87 70 82. When a >> variable's value is equal to any of these... > Don't try to convince me that there

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Stephen Taylor
Igor Stasenko wrote: You have some integers: 0 83 67 77 68 72 80 112 113 87 70 82. When a variable's value is equal to any of these... Don't try to convince me that there are sort of problems which can be solved only by using case statement :) You didn't answer the question though. First,

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Igor Stasenko
On 13 February 2011 17:44, Ricardo Moran wrote: > Of course discussion is good. But turning your position into a religion and > blaming other parties ignorance is bad. That's what the discussion seemed to > be heading (at least to me) and I just tried to avoid that. > Maybe I'm just too new in thi

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Janko Mivšek
t; seconds slower? There's always another side to what "efficiency" means > to everyone. > > My 2 cents! > > :) > > > > - > Benoit St-Jean > Yahoo! Messenger: bstjean > A standpoint is an intellectual horizon of radius zero. > (Albert Einstein) > > >

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Benoit St-Jean
mage (effectively removing it), but leave it in place for those who want to use it their own code?? Bill From: pharo-project-boun...@lists.gforge.inria.fr [pharo-project-boun...@lists.gforge.inria.fr] On Behalf Of Benoit St-Jean [bstj...@yahoo.com] Sent: Sunday, February

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Nicolas Cellier
Yes, I myself find the implementation hackish, but I wish I could see more pragmatic analysis based on exact usage of this message. The discussion isn't going forward, every one camping on its position. 1) Where is the message used ? 2) How would you refactor the senders ? 3) Does speed degrade ? 4

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Schwab,Wilhelm K
t-boun...@lists.gforge.inria.fr] On Behalf Of Benoit St-Jean [bstj...@yahoo.com] Sent: Sunday, February 13, 2011 9:43 AM To: Pharo-project@lists.gforge.inria.fr Subject: Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise: Let's get to the point here... Most people

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Ricardo Moran
Of course discussion is good. But turning your position into a religion and blaming other parties ignorance is bad. That's what the discussion seemed to be heading (at least to me) and I just tried to avoid that. Maybe I'm just too new in this community (and smalltalk in general, for that matter)

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Benoit St-Jean
& simplicity are good, not evil in Smalltalk! - Benoit St-Jean Yahoo! Messenger: bstjean A standpoint is an intellectual horizon of radius zero. (Albert Einstein) From: Levente Uzonyi To: Pharo-project@lists.gforge.inria.fr Sent: Sun, Febr

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Levente Uzonyi
On Sun, 13 Feb 2011, Sven Van Caekenberghe wrote: On 12 Feb 2011, at 18:41, Levente Uzonyi wrote: ~27x slowdown in this case. I personally never heard of #caseOf:otherwise ! It feels like a hack that is not often needed. You don't need it often, but it's sometimes useful. If after wri

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Levente Uzonyi
On Sun, 13 Feb 2011, Igor Stasenko wrote: On 13 February 2011 02:58, Levente Uzonyi wrote: On Sun, 13 Feb 2011, Igor Stasenko wrote: Please read the Ian's paper about switch statement vs message sends.. You will discover something surprising for you. Link please? That's C's switch statem

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Igor Stasenko
On 13 February 2011 09:05, Tudor Girba wrote: > Hi, > > I also think we do not need caseOf: in the default distribution. > > It is probably useful for some cases (like dealing with integers from some > external source as mentioned by Levente), but those cases are so rare that we > should not aff

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Stéphane Ducasse
You got the process :) I like that we really discuss (because sometimes I'm wrong and I have no problem to change my mind :) I reminded me the discussion we got two yeras ago about number and nicolas convinced me that his approach was good about float (not been mathematical numbers). Stef On F

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Alain Plantec
Le 13/02/2011 04:05, Ricardo Moran a écrit : Ok, guys... I'm sorry to interrupt this polite discussion, but this is taking nowhere. no, it allows people to make their own opinion. interesting thread. Now I can say that I would be more for getting rid of case of. thanks Alain

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Sven Van Caekenberghe
On 12 Feb 2011, at 18:41, Levente Uzonyi wrote: > ~27x slowdown in this case. I personally never heard of #caseOf:otherwise ! It feels like a hack that is not often needed. If after writing correct code you need to optimize integer/byte handling, there are many solutions, check any book on al

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-13 Thread Tudor Girba
Hi, I also think we do not need caseOf: in the default distribution. It is probably useful for some cases (like dealing with integers from some external source as mentioned by Levente), but those cases are so rare that we should not affect everyone with this message. Cheers, Doru On 13 Feb 2

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Stéphane Ducasse
Hi ricardo, igor and levente I really want to remove caseOf: since years. Why: - conceptually wrong (even if this may be nice to have for $A and numbers) - to me it looks like coming from another age - never needs to use it: of course other people may of course -

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 13 February 2011 04:05, Ricardo Moran wrote: > But please don't ban people who are willing to sacrifice a little > readability for performance reasons. Thanks. Then C language is your choice! It is full of such sacrifices :) But can i ask you to not turn smalltalk into C , please? > Best reg

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Ricardo Moran
Ok, guys... I'm sorry to interrupt this polite discussion, but this is taking nowhere. Having such strong arguments (for or against) is not helpful for anybody. We all know using #caseOf:otherwise: it's not exactly good style, but sometimes you need to compromise between design and efficiency, and

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 13 February 2011 02:58, Levente Uzonyi wrote: > On Sun, 13 Feb 2011, Igor Stasenko wrote: > >> Please read the Ian's paper about switch statement vs message sends.. >> You will discover something surprising for you. > > Link please? > > Here: www.piumarta.com/pepsi/objmodel.pdf- -

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sat, 12 Feb 2011, Miguel Cobá wrote: El dom, 13-02-2011 a las 02:58 +0100, Levente Uzonyi escribió: On Sat, 12 Feb 2011, Miguel Cobá wrote: El dom, 13-02-2011 a las 02:26 +0100, Levente Uzonyi escribió: I know what's premature optimization. It appear that you know but doesn't understan

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Miguel Cobá
El dom, 13-02-2011 a las 02:58 +0100, Levente Uzonyi escribió: > On Sat, 12 Feb 2011, Miguel Cobá wrote: > > > El dom, 13-02-2011 a las 02:26 +0100, Levente Uzonyi escribió: > > > >> I know what's premature optimization. > > > > It appear that you know but doesn't understand. See below. > > > >>

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sun, 13 Feb 2011, Igor Stasenko wrote: Please read the Ian's paper about switch statement vs message sends.. You will discover something surprising for you. Link please? Levente Levente Levente -- Best regards, Igor Stasenko AKA sig. -- Best regards, Igor Stasenk

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sat, 12 Feb 2011, Miguel Cobá wrote: El dom, 13-02-2011 a las 02:26 +0100, Levente Uzonyi escribió: I know what's premature optimization. It appear that you know but doesn't understand. See below. What I do differently than other people (including you) is: - if I can choose from differ

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 13 February 2011 02:26, Levente Uzonyi wrote: > On Sun, 13 Feb 2011, Igor Stasenko wrote: > >> On 13 February 2011 00:59, Levente Uzonyi wrote: >>> >>> On Sun, 13 Feb 2011, Igor Stasenko wrote: >>> Don't try to convince me that there are sort of problems which can be solved only by u

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Miguel Cobá
El dom, 13-02-2011 a las 02:26 +0100, Levente Uzonyi escribió: > I know what's premature optimization. It appear that you know but doesn't understand. See below. > What I do differently than other > people (including you) is: > - if I can choose from different solutions for some problem, then

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sun, 13 Feb 2011, Igor Stasenko wrote: On 13 February 2011 00:59, Levente Uzonyi wrote: On Sun, 13 Feb 2011, Igor Stasenko wrote: Don't try to convince me that there are sort of problems which can be solved only by using case statement :) We all know that it can be solved, but the solut

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 13 February 2011 00:59, Levente Uzonyi wrote: > On Sun, 13 Feb 2011, Igor Stasenko wrote: > >> Don't try to convince me that there are sort of problems which can be >> solved only by using case statement :) > > We all know that it can be solved, but the solution won't be nicer at all, > instead

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sun, 13 Feb 2011, Igor Stasenko wrote: Don't try to convince me that there are sort of problems which can be solved only by using case statement :) We all know that it can be solved, but the solution won't be nicer at all, instead it will be a lot slower. First, get rid of these integer

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 13 February 2011 00:17, Levente Uzonyi wrote: > On Sat, 12 Feb 2011, Igor Stasenko wrote: > >> oh come on. Switch statement should live where it belongs to: C code. > > It's nothing like C's switch statement, and I'm sure you know that. > >> >> Why we should support this ridiculous syntax const

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Sat, 12 Feb 2011, Igor Stasenko wrote: oh come on. Switch statement should live where it belongs to: C code. It's nothing like C's switch statement, and I'm sure you know that. Why we should support this ridiculous syntax constructs in smalltalk? What's so ridiculous about it? IMO: A

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Igor Stasenko
On 12 February 2011 18:41, Levente Uzonyi wrote: > On Fri, 11 Feb 2011, stephane ducasse wrote: > >> Hi guys >> >> let us do another pass at cleaning and realigning the system. >> Could we agree to deprecate caseOf: and caseOf:otherwise:? >> it will simply the compiler, decompiler and also we do n

Re: [Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread Levente Uzonyi
On Fri, 11 Feb 2011, stephane ducasse wrote: Hi guys let us do another pass at cleaning and realigning the system. Could we agree to deprecate caseOf: and caseOf:otherwise:? it will simply the compiler, decompiler and also we do not need that at all. | z | z := {[#a]->[1+1]. ['b' asSymbol]->[2

[Pharo-project] could we agree to remove caseOf: and caseOf:otherwise:

2011-02-12 Thread stephane ducasse
Hi guys let us do another pass at cleaning and realigning the system. Could we agree to deprecate caseOf: and caseOf:otherwise:? it will simply the compiler, decompiler and also we do not need that at all. | z | z := {[#a]->[1+1]. ['b' asSymbol]->[2+2]. [#c]->[3+3]}. #b caseOf: z => "| z | z :=