On 13-05-06 09:46 AM, Matthieu Monrocq wrote:

> I would therefore propose:
> 
> - zip: only on collections of equal length
> - zipcut: stop iteration as soon as the shortest collection is exhausted
> - zipfill: fill the "void" (somehow: default value, Option<T>, ...)
> 
> This way we have all 3 variants, with descriptive names for those 2 who
> introduce specific behavior.

This seems to me exactly the sort of "customize how you continue in the
face of a rare event that has multiple reasonable forms of recovery"
that conditions are made for. Do you think they'd be appropriate?

-Graydon


_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to