I'd prefer #when:do: rather than #onAnnouncement:do: - Francisco On 5 Aug 2013, at 18:01, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
On Aug 5, 2013, at 4:18 PM, Nicolas Cellier <nicolas.cellier.aka.nice@gmail.com> wrote:
false polymorphism with exception handling?
indeed.
When I read code and I see on:do: there is a big sign that shows up in my mind: exception.
In addition when I look inside the senders I get false sense of use.
This is the case for example with on:do: for announcement which I really do not like. I think that we will rename on:do: into onAnnouncement:do: because I did not see one case where suddenly I would like to mix exception with announcement.
Stef
2013/8/5 Mariano Martinez Peck <marianopeck@gmail.com> Indeed, I thought the same. Stef, could you tell us why implementing on:do: is wrong?
On Mon, Aug 5, 2013 at 10:30 AM, Martin Dias <tinchodias@gmail.com> wrote: Hi
Thanks Stef for fighting with the leak and thanks Max for the fast response.
I think was me who added the method #on:do:, and my reasoning was:
- FileStream has #fileNamed: and #fileNamed:do: - PositionableStream has #on: - I needed the analog to FileStream>>fileNamed:do: in PositionableStream
So, I created #on:do:. It looked consistent.
MartÃn
On Sun, Aug 4, 2013 at 5:02 PM, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
impressive :) Tx guys. We are fighting with memory leaks like mad :)
Stef
On Aug 4, 2013, at 4:49 PM, Max Leske <maxleske@gmail.com> wrote:
Done.
Name: ConfigurationOfFuel-MaxLeske.207 Author: MaxLeske Time: 4 August 2013, 4:49:17.037 pm UUID: 5cc59075-e365-4a58-a20b-22e40b2b70c9 Ancestors: ConfigurationOfFuel-MartinDias.206
* created new version 1.9.2 for development * pointed development to 1.9.2 * includes changes Camillo wanted to introduce into 1.9.1 (DateAndTime fix)
On 04.08.2013, at 16:35, Max Leske <maxleske@gmail.com> wrote:
Yeah, no problem. I'll get on it right away.
Max
On 04.08.2013, at 16:10, Stéphane Ducasse <stephane.ducasse@inria.fr> wrote:
Hi guys
can you rename this method?
on: aCollectionOrStream do: aBlock "Evaluates a block with a new stream based on the collection or stream. Answers the result of the block evaluation. Follows the style of FileStream>>fileNamed:do:." | aStream | aStream := self on: aCollectionOrStream. [ ^ aBlock value: aStream ] ensure: [ aStream close ]
Please do not use on:do: for something that is not about exception (and announcements).
It is too confusing and refactor after.
Stef
_______________________________________________ Pharo-fuel mailing list Pharo-fuel@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-fuel
_______________________________________________ Pharo-fuel mailing list Pharo-fuel@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-fuel
_______________________________________________ Pharo-fuel mailing list Pharo-fuel@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-fuel
-- Mariano http://marianopeck.wordpress.com