scottmcm

Results 253 comments of scottmcm

> I feel like we shouldn't tie any kind of "you have to change your code" changes to updating rust-version; that would give people the (correct) impression of breakage when...

Even just `.unwrap!()` would mean better locations, without needing https://github.com/rust-lang/rfcs/pull/2091... (And the trait for `?` would let it work over `Result` and `Option` with the same macro expansion.)

Oh, good point -- I don't know why I had it in my head that it was always ⅔. I updated my post above, but don't have a particularly strong...

I have not. Given the description of "experimental and unstable; for experiments" I suspect they know, or at least wouldn't be too concerned about it. I was just trying to...

I feel pretty strongly that it shouldn't be `drain` because the important part to me about `drain` is that it modifies the receiver even if the return value is not...

Can you say more about why _you_ think this particular combination is common enough to belong in `itertools`? (The code itself is fine, though could be improved with a few...

Note that things like `array_windows` for iterators are under discussion for iterators in std, see conversations like https://rust-lang.zulipchat.com/#narrow/stream/219381-t-libs/topic/Iterator.3A.3A.7Bpairwise.2C.20windows.7D/near/224587771 As I understand it `std` didn't want the tuple ones because of...

The obvious question to me is whether it's needed vs the other things that currently exist, like - https://docs.rs/itertools/0.10.0/itertools/fn.unfold.html - https://doc.rust-lang.org/nightly/std/iter/fn.from_fn.html How hard is the example to encode in one...

Another thought: I might like this better if it had a name more evocative of *how* it turns the closure into an iterator. Like I'm a fan of `unfold` because...

If you need a `map` with some internal state, maybe you want https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.scan ?