summaryrefslogtreecommitdiff
path: root/testsuite/tests/safeHaskell/overlapping/SH_Overlap3.hs
blob: 8ffa53f84b918a7aa6a9556ee78e38a5a03041d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{-# LANGUAGE Unsafe #-}
{-# LANGUAGE FlexibleInstances #-}

-- | Same as SH_Overlap1, but module where overlap occurs (SH_Overlap3) is
-- marked `Unsafe`. Compilation should succeed (symmetry with inferring safety).
module SH_Overlap3 where

import SH_Overlap3_A

instance
  C [a] where
    f _ = "[a]"

test :: String
test = f ([1,2,3,4] :: [Int])