Commit cdddc521 authored by Simon Peyton Jones's avatar Simon Peyton Jones

TH empty case expressions now ok (with -XEmptyCase)

parent 03753b0f
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TemplateHaskell, EmptyCase #-}
-- Trac #2431: empty case expression
-- currently rejected
-- now accepted
module Main where
Case expression with no alternatives
When splicing a TH expression: case 'a' of
In the expression: $(caseE (litE $ CharL 'a') [])
In an equation for `f': f = $(caseE (litE $ CharL 'a') [])
......@@ -138,7 +138,7 @@ test('T2817', normal, compile, ['-v0'])
test('T2713', normal, compile_fail, ['-v0'])
test('T2674', normal, compile_fail, ['-v0'])
test('T2931', normal, compile, ['-v0'])
test('TH_emptycase', normal, compile_fail, ['-v0'])
test('TH_emptycase', normal, compile, ['-v0'])
test('T2386', extra_clean(['T2386_Lib.hi', 'T2386_Lib.o']),
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment