Commit 2026-09-04 15:28 ab3a27a9

View on Github →

feat(Translate): try all translation pairings until one succeeds (#42861) This PR allows to_dual to add translations between two sets of constants by trying all possible pairings, instead of only going for the respective pairing. This is possible thanks to #40365, which made to_dual validate all translations. This is useful for

  • to_dual (attr := simps) on e.g. an Iso or Comma, since the projections hom/inv and left/right are dual to eachother.
  • to_dual on structures where the fields are reordered, such as Comma. I think the tiny slowdown is worth the convenience.

Estimated changes