GNOME Bugzilla – Bug 781641
Add additional query functions to Traversable<G>
Last modified: 2017-12-11 13:03:42 UTC
Created attachment 350270 [details] [review]
Patch with additional Traversable<G> funcions
Added function to test if only a single element matches a predicate. This function can be faster than counting, since the loop can be abandon if more than one matching element is found.
Added function to count elements matching a predicate. Named the function count_match, so if a family of functions are created in the future, they can follow the count_xxx template.