Generic enumerator extensions (predates extension methods)