[iterators] Avoid assigning an iterator having singular value (uninitialized) in flatten_iterator assignment operators.

Explicitly define flatten_iterator copy assignment operator.
[iterators] Fix return types of templated assignment operators.