gitlab-ci: Move hadrian-ghc-in-ghci job first
[ghc.git] / testsuite / tests / typecheck / should_compile / TcTypeSymbolSimple.hs
1 {-# LANGUAGE DataKinds, TypeOperators, TypeFamilies #-}
2 module TcTypeNatSimple where
3 import GHC.TypeLits
4 import Data.Proxy
5
6 --------------------------------------------------------------------------------
7 -- Test evaluation
8
9 te1 :: Proxy (AppendSymbol "" x) -> Proxy x
10 te1 = id
11
12 te2 :: Proxy (AppendSymbol x "") -> Proxy x
13 te2 = id
14
15 te3 :: Proxy (AppendSymbol "type" "level") -> Proxy "typelevel"
16 te3 = id
17
18 --------------------------------------------------------------------------------
19 -- Test interactions with inerts
20
21 tei1 :: Proxy (AppendSymbol y x) -> Proxy x -> ()
22 tei1 _ _ = ()
23
24 tei2 :: Proxy (AppendSymbol "foo" x) -> ()
25 tei2 _ = ()
26
27 tei3 :: Proxy (AppendSymbol x "foo") -> ()
28 tei3 _ = ()