ash icon indicating copy to clipboard operation
ash copied to clipboard

Add `extend_next` method to extendable structs

Open Rua opened this issue 1 year ago • 1 comments

Like the extend method of many standard containers, this would take an iterator of extension structs and add them all:

pub fn extend_next(
    self,
    next: impl IntoIterator<Item = &'a mut dyn ExtendsWhatever>,
) -> Self

Rua avatar Apr 14 '24 10:04 Rua

That seems like a lot of extra generated code for something that could be addressed with a three-line for loop on the caller's side.

Ralith avatar Apr 14 '24 20:04 Ralith