summaryrefslogtreecommitdiff
path: root/testsuite/tests/type-data/should_fail/TDTagToEnum.hs
blob: ef0ba0b49653e6cf864ebe5f9b7cd2537406b8b1 (plain)
1
2
3
4
5
6
7
8
9
10
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE TypeData #-}
module TDTagToEnum where

import GHC.Exts (tagToEnum#)

type data Letter = A | B | C

f :: Letter
f = tagToEnum# 0#