I have an app where I create the list of tabs at runtime through the use of an iterator. The allocation of a Vec which is then immediately iterated upon seemed a bit wasteful. If there was a reason for the particular API, please do tell. If not, here is a simple change which changes the function to accept any IntoIterator, which would then avoid this allocation in my case. Further, the existing interface should be preserved, as Vec implements IntoIterator, in addition to that the size_hit will return the length of the Vec.
Thank you for a great couple of widgets in this library!
I have an app where I create the list of tabs at runtime through the use of an iterator. The allocation of a Vec which is then immediately iterated upon seemed a bit wasteful. If there was a reason for the particular API, please do tell. If not, here is a simple change which changes the function to accept any IntoIterator, which would then avoid this allocation in my case. Further, the existing interface should be preserved, as Vec implements IntoIterator, in addition to that the size_hit will return the length of the Vec.
Thank you for a great couple of widgets in this library!