scala/scala — pull request #1732 by retronym (2012-12-08 10:47:55+00:00)
Title: SI-6690 Release reference to last dequeued element.

Avoids leaks in MutableList and its more better known child,
mutable.Queue, when the last element is dequeued or when we
take the tail of a one element collection.

Refactors copy/pasted code between the two implementations of
tail.

Review by @axel22