Commit cd857dd4 authored by Ben Gamari's avatar Ben Gamari Committed by Ben Gamari

SetLevels: Substitute in ticks in lvlMFE

Previously SetLevels.lvlMFE would fail to substitute in ticks, unlike
lvlExpr.  This lead to #13481. Fix this.

Test Plan: `make test TEST=T12622 WAY=ghci`

Reviewers: austin, simonpj

Reviewed By: simonpj

Subscribers: simonpj, rwbarton, thomie

GHC Trac Issues: #13481

Differential Revision:
parent 542f89ff
......@@ -558,7 +558,8 @@ lvlMFE env _ (_, AnnType ty)
-- and then inline lvl. Better just to float out the payload.
lvlMFE env strict_ctxt (_, AnnTick t e)
= do { e' <- lvlMFE env strict_ctxt e
; return (Tick t e') }
; let t' = substTickish (le_subst env) t
; return (Tick t' e') }
lvlMFE env strict_ctxt (_, AnnCast e (_, co))
= do { e' <- lvlMFE env strict_ctxt e
......@@ -148,7 +148,7 @@ test('PopCnt', omit_ways(['ghci']), multi_compile_and_run,
['PopCnt', [('PopCnt_cmm.cmm', '')], ''])
test('T12059', normal, compile_and_run, [''])
test('T12433', normal, compile_and_run, [''])
test('T12622', expect_broken_for(13481, ['ghci']), multimod_compile_and_run, ['T12622', '-O'])
test('T12622', normal, multimod_compile_and_run, ['T12622', '-O'])
test('T12757', normal, compile_and_run, [''])
test('T12855', normal, compile_and_run, [''])
test('T9577', [ unless(arch('x86_64') or arch('i386'),skip),
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment