[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-users] removeSuchThat: bug or feature?



ok, I committed that.

On Apr 28, 2004, at 7:25 AM, Till Bovermann wrote:

should be

+ Collection {
removeAllSuchThat { | function |
		var removedItems, copy;
		// changed:
		removedItems = this.class.new;
		copy = this.copy;
		copy.do { | item, i |
			if ( function.value(item, i) )
			{
				this.remove(item);
				// changed:
				removedItems = removedItems.add(item);
			}
		};
		^removedItems
	}
}


regards
Till