immutable
immutable copied to clipboard
Feature Request: Allow to append/prepend multiple values
With go slices it is possible to append multiple values:
s = append(s, anotherSlice...)
This is quite cumbersome currently with immutable, and also would create a lot of unnecessary lists.
Would it be possible to add support for this?
If you need to add multiple values initially, you can use the ListBuilder
. I could maybe see optimizing for append/prepend on existing lists.
Actually, initially the list is most of the times empty but during runtime slices of elements should be added to it. So it would be nice to have this for existing lists.