Traits for “zipping” types, walking through two structures and checking that they match.
- eq_zip 🔒Generates a Zip impl that requires the two values be equal. Suitable for atomic, scalar values.
Ziptrait walks two values, invoking the
Zippermethods where appropriate, but otherwise requiring strict equality.
- When we zip types, we basically traverse the structure, ensuring that it matches. When we come to types/lifetimes, we invoke the callback methods in the zipper to match them up. Primarily used during unification or similar operations.