mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-06 10:11:44 +00:00
Generalise compare_fields to work with iterators (#4823)
## Proposed Changes Add `compare_fields(as_iter)` as a field attribute to `compare_fields_derive`. This allows any iterable type to be compared in the same as a slice (by index). This is forwards-compatible with tree-states types like `List` and `Vector` which can not be cast to slices.
This commit is contained in:
1
Cargo.lock
generated
1
Cargo.lock
generated
@@ -1120,6 +1120,7 @@ name = "compare_fields"
|
||||
version = "0.2.0"
|
||||
dependencies = [
|
||||
"compare_fields_derive",
|
||||
"itertools",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
||||
Reference in New Issue
Block a user