[Git][ghc/ghc][wip/sjakobi/T9074] Add regression test for #9074