T13984.hs 181 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
{-# LANGUAGE TemplateHaskell #-}
module Panic where

import Language.Haskell.TH

expr :: IO Exp
expr = runQ $ do
  name <- newName "foo"
  [| do $(varP name) <- pure (); pure () |]