Skip to content

Replace queryCygwinTerminal with Win32's isMinTTYHandle

Ryan Scott requested to merge RyanGlScott/ghc:is-mintty-handle into master

SysTools.Terminal.queryCygwinTerminal now exists in the Win32 library under the name isMinTTYHandle since Win32-2.5.0.0. (GHC 8.4.4 ships with Win32-2.6.1.0, so this is well within GHC's support window.) We can therefore get replace queryCygwinTerminal with isMinTTYHandle and delete quite a bit of code from SysTools.Terminal in the process.

Along the way I needed to replace some uses of #if defined x with #if defined(x) to please the CI linters.

Edited by Ryan Scott

Merge request reports