Skip to content

Commit e6086cc

Browse files
committed
Auto merge of #148034 - dianqk:matchbr-copy, r=cjgillot
Simplify the canonical enum clone branches to a copy statement I have overhauled MatchBranchSimplification in this PR. This pass tries to unify statements one by one, which is more readable and extensible. This PR also unifies the following pattern that is mostly generated by GVN into one basic block that contains the copy statement: ```rust match a { Foo::A(_) => *a, Foo::B => Foo::B } ``` Fixes rust-lang/rust#128081.
2 parents e698f0b + b14d462 commit e6086cc

0 file changed

File tree

    0 commit comments

    Comments
     (0)