Multy-core CPUs
Sebastian Sastre
ssastre at seaswork.com
Mon Oct 22 12:10:41 UTC 2007
> > The Erlang way: don't care about the order of arrival of
> the messages,
> > and let the developer care about that when it's important.
> >
>
> Yes, a simple example when i need to have correct order:
> Collection>>do:
>
> to print an array i'll have all items ordered from start to
> end , not in random order.
>
> And of course there are cases, when i don't need to have
> items iterated in specific order. When i simply need to visit
> all items in collection to send a message to them.
>
> So, we need at least 2 messages to reflect a different behaviour:
> #do:
> and
> #orderedDo:
>
> and that's only the simplest case...
>
> > Giovanni
> >
>
Are you sure Igor? why you will a developer use an OrderedCollection if
he/she don't care about order? I think is more proper to use a aSet or aBag
even to perform something to the elements of that ordered collection in an
unordered way instead of (pre)asuming how #do: implements the traversal.
Perhaps you found another contraexample/s.
Cheers,
Sebastian
More information about the Squeak-dev
mailing list
|