Closed luis-cortes closed 3 years ago
Could you please add a description to the PR explaining why you're making this change, linking to any relevant discussions, etc?
Could you please add a description to the PR explaining why you're making this change, linking to any relevant discussions, etc?
Sorry @zach-klippenstein was getting late last night. I've updated the description with some more info.
Context
@helios175 and I are working on various improvements to Cycler this week as a part of hack week.
Overview
Datasource was introduced to make it easy to implement a list without forcing users to implement the full
List
interface. However:DataSource
andAbstractList
have the exact same abstract methodsDataSource
wrapper has some implications in our code. It forces users to unnecessarily create a new wrapper on every invocation oftoDataSource()
(even when the passed in list is the same).List
(or some data structure that could easily be converted toList
via std lib extensions). RemovingDataSource
eliminates an extra step when trying to update Cycler's data.