Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ansi-terminal/ansi-terminal.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ Library
Build-Depends: base >= 4.8.0.0 && < 5
, ansi-terminal-types == 1.1.3
, colour >= 2.1.0
if impl(ghc >= 9.10)
Build-Depends: ghc-internal >= 9.1001.0
if os(windows)
Hs-Source-Dirs: win
Other-Modules: System.Console.ANSI.Windows.Foreign
Expand Down
2 changes: 1 addition & 1 deletion ansi-terminal/stack.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
snapshot: lts-24.0 # GHC 9.10.2
snapshot: lts-24.10 # GHC 9.10.2
flags:
ansi-terminal:
example: false
12 changes: 12 additions & 0 deletions ansi-terminal/win/System/Console/ANSI/Windows/Win32/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,29 @@ import Foreign.C.String ( peekCWString )
import Foreign.C.Types ( CChar, CInt (..), CShort (..), CWchar )
import Foreign.Ptr ( Ptr, nullPtr )
import Foreign.StablePtr ( StablePtr, freeStablePtr, newStablePtr )
#if MIN_VERSION_base(4,20,0)
import GHC.Internal.IO.Handle.Types ( Handle (..), Handle__ (..) )
import GHC.Internal.IO.FD ( FD(..) ) -- A wrapper around an Int32
#else
import GHC.IO.Handle.Types ( Handle (..), Handle__ (..) )
import GHC.IO.FD ( FD(..) ) -- A wrapper around an Int32
#endif
import Numeric ( showHex )
import System.IO.Error ( ioeSetErrorString )

#if defined(__IO_MANAGER_WINIO__)
#if MIN_VERSION_base(4,20,0)
import GHC.Internal.IO.Exception
( IOErrorType (InappropriateType), IOException (IOError), ioException )
import GHC.Internal.IO.SubSystem ( (<!>) )
import GHC.Internal.IO.Windows.Handle ( ConsoleHandle, Io, NativeHandle, toHANDLE )
#else
import GHC.IO.Exception
( IOErrorType (InappropriateType), IOException (IOError), ioException )
import GHC.IO.SubSystem ( (<!>) )
import GHC.IO.Windows.Handle ( ConsoleHandle, Io, NativeHandle, toHANDLE )
#endif
#endif

type Addr = Ptr ()
type BOOL = Bool
Expand Down
Loading