i did some experiments with the "reference" equivalents of snapshot and data source types (NSDiffableDataSourceSnapshotReference & UITableViewDiffableDataSourceReference vs NSDiffableDataSourceSnapshot & UITableViewDiffableDataSource). partly for better understanding the diffable machinery, partly for Obj-C compatibility, partly due to the fact that using generics is not convenient for the model objects in question due to their profound viral effect on the surrounding code base.
it actually works very well. but i noticed that my item value types are not hashable... if i mark them hashable i can see hashValue / hashInto methods being called and everything works as expected, but if i don't mark them hashable the hash methods are not called, and everything still works.. how does it work?
Note that hashability is required when using swift wrapper types (NSDiffableDataSourceSnapshot & UITableViewDiffableDataSource)
it actually works very well. but i noticed that my item value types are not hashable... if i mark them hashable i can see hashValue / hashInto methods being called and everything works as expected, but if i don't mark them hashable the hash methods are not called, and everything still works.. how does it work?
Note that hashability is required when using swift wrapper types (NSDiffableDataSourceSnapshot & UITableViewDiffableDataSource)