Skip to content

Commit 817720c

Browse files
authored
Rollup merge of #138799 - joboet:extend-tuple, r=Mark-Simulacrum
core: simplify `Extend` for tuples This is an alternative to #137400. The current macro is incredibly complicated and introduces subtle bugs like calling the `extend_one` of the individual collections in backwards order. This PR drastically simplifies the macro by removing recursion and moving the specialization out of the macro. It also fixes the ordering issue described above (I've stolen the test of the new behaviour from #137400). Additionally, the 1-tuple is now special-cased to allow taking advantage of the well-optimized `Extend` implementations of the individual collection.
2 parents 3be6803 + af66ece commit 817720c

File tree

2 files changed

+258
-196
lines changed

2 files changed

+258
-196
lines changed

0 commit comments

Comments
 (0)