Hmm,
Should I add it as a ticket to the lighthouse?

It looks like they only accept bugfixes?

On 2 Cze, 11:07, Robert <[email protected]> wrote:
> I believe intersection method would be good extension to the Array
> class. There is combine method (set sum) but no set intersection.
>
> It could look like this:
>
> Array.implement({
>     attest: function(item, array) {
>         if (!array.contains(item)) this.erase(item);
>         return this;
>     },
>     intersection: function(array) {
>         for (var i = 0, l = this.length; i < l; i++)
> this.attest(this[i], array);
>         return this;
>     }
>
> });
>
> What You think?

Reply via email to