Hacker News new | ask | show | jobs
by aalvarado 4213 days ago
Yup, seeing method signatures like these is discouraging:

``` core::iter::Zip<core::iter::FilterMap<'_, (&std::collections::hash::set::HashSet<attr::Attribute>, &attr::Attribute), &attr::Attribute, core::iter::Zip<core::iter::Repeat<&std::collections::hash::set::HashSet<attr::Attribute>>, core::iter::Map<'_, (&attr::Attribute, &()), &attr::Attribute, std::collections::hash::map::Entries<'_, attr::Attribute, ()>>>>, core::iter::FilterMap<'_, (&std::collections::hash::set::HashSet<attr::Attribute>, &attr::Attribute), &attr::Attribute, core::iter::Zip<core::iter::Repeat<&std::collections::hash::set::HashSet<attr::Attribute>>, core::iter::Map<'_, (&attr::Attribute, &()), &attr::Attribute, std::collections::hash::map::Entries<'_, attr::Attribute, ()>>>>> ``

3 comments

Ha, we hate them too, which is why we're so eager to finalize their design so that we can replace all of that hideous garbage with just `impl Iterator`. :)

And who knows, it might happen for 1.0 if enough people push on the design and are willing to put in the legwork of implementing it.

thanks for your hard work. Sometimes we take simplicity for granted!
What is that, if I may ask?
That particular type is an Iterator over two HashSet intersections zipped together. I'm looking forward to getting rid of it!
This is a huge ergonomic issue that the team is very aware of. There are plans to fix it post 1.0.