Move iterator implementations to impl namespace.