[squeak-dev] The Trunk: Collections-eem.462.mcz

Nicolas Cellier nicolas.cellier.aka.nice at gmail.com
Mon Oct 3 16:47:27 UTC 2011


Ah thanks for correcting.
I lost this method somewhere when trying to revert from inbox
suggestion to the trunk ancestry...

Nicolas

2011/10/3  <commits at source.squeak.org>:
> Eliot Miranda uploaded a new version of Collections to project The Trunk:
> http://source.squeak.org/trunk/Collections-eem.462.mcz
>
> ==================== Summary ====================
>
> Name: Collections-eem.462
> Author: eem
> Time: 2 October 2011, 7:11:42.336 pm
> UUID: 50129323-386f-454d-8569-da4400cdc90e
> Ancestors: Collections-nice.461
>
> With SequenceableCollection>size being a subclassResponsibility
> LinkedList must implement size.  WIth this
>
>        SequenceableCollection allSubclasses select:
>                [:c| (c whichClassIncludesSelector: #size)
>                        == SequenceableCollection]
>
>        =>      an OrderedCollection(SourceFileArray)
>
> which is fine since SourceFileArray is abstract.
>
> =============== Diff against Collections-nice.461 ===============
>
> Item was added:
> + ----- Method: LinkedList>>size (in category 'accessing') -----
> + size
> +       "Answer how many elements the receiver contains."
> +
> +       | tally |
> +       tally := 0.
> +       self do: [:each | tally := tally + 1].
> +       ^ tally!
>
>
>



More information about the Squeak-dev mailing list