Skip to content

Commit d7d1320

Browse files
committed
Fix warnings on ghc-8.0.2
1 parent 0aa10e1 commit d7d1320

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

System/OsString/Internal/Types.hs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ instance Show WindowsString where
6868
pattern WS :: BS.ShortByteString -> WindowsString
6969
pattern WS { unWS } <- WindowsString unWS where
7070
WS a = WindowsString a
71+
#if __GLASGOW_HASKELL__ >= 802
7172
{-# COMPLETE WS #-}
73+
#endif
7274

7375

7476
instance Lift WindowsString where
@@ -93,7 +95,9 @@ instance Show PosixString where
9395
pattern PS :: BS.ShortByteString -> PosixString
9496
pattern PS { unPS } <- PosixString unPS where
9597
PS a = PosixString a
98+
#if __GLASGOW_HASKELL__ >= 802
9699
{-# COMPLETE PS #-}
100+
#endif
97101

98102
instance Lift PosixString where
99103
lift (PosixString bs)
@@ -127,13 +131,17 @@ instance Show PosixChar where
127131
pattern WW :: Word16 -> WindowsChar
128132
pattern WW { unWW } <- WindowsChar unWW where
129133
WW a = WindowsChar a
134+
#if __GLASGOW_HASKELL__ >= 802
130135
{-# COMPLETE WW #-}
136+
#endif
131137

132138
-- | Just a short bidirectional synonym for 'PosixChar' constructor.
133139
pattern PW :: Word8 -> PosixChar
134140
pattern PW { unPW } <- PosixChar unPW where
135141
PW a = PosixChar a
142+
#if __GLASGOW_HASKELL__ >= 802
136143
{-# COMPLETE PW #-}
144+
#endif
137145

138146
#if defined(mingw32_HOST_OS) || defined(__MINGW32__)
139147
type PlatformChar = WindowsChar

0 commit comments

Comments
 (0)