ghcid icon indicating copy to clipboard operation
ghcid copied to clipboard

Windows installation, ambiguous occurrence ‘wM_SETICON’

Open new-user-name opened this issue 1 year ago • 1 comments

Windows 11, not WSL2, plain Windows installation from terminal.

src\Language\Haskell\Ghcid\Terminal.hs:66:21: error:
    Ambiguous occurrence ‘wM_SETICON’
    It could refer to
       either ‘Graphics.Win32.Message.wM_SETICON’,
              imported from ‘Graphics.Win32.Message’ at src\Language\Haskell\Ghcid\Terminal.hs:16:1-29
           or ‘Language.Haskell.Ghcid.Terminal.wM_SETICON’,
              defined at src\Language\Haskell\Ghcid\Terminal.hs:21:1
   |
66 |     sendMessage wnd wM_SETICON iCON_SMALL $ fromIntegral $ castPtrToUINTPtr icon
   |                     ^^^^^^^^^^

src\Language\Haskell\Ghcid\Terminal.hs:66:32: error:
    Ambiguous occurrence ‘iCON_SMALL’
    It could refer to
       either ‘Graphics.Win32.Message.iCON_SMALL’,
              imported from ‘Graphics.Win32.Message’ at src\Language\Haskell\Ghcid\Terminal.hs:16:1-29
           or ‘Language.Haskell.Ghcid.Terminal.iCON_SMALL’,
              defined at src\Language\Haskell\Ghcid\Terminal.hs:25:1
   |
66 |     sendMessage wnd wM_SETICON iCON_SMALL $ fromIntegral $ castPtrToUINTPtr icon
   |                                ^^^^^^^^^^

and so on. I know Windows and Haskell are enemies, but for some reason I need this build not under/against WSL2.

new-user-name avatar Apr 09 '23 22:04 new-user-name

Issue resolved.

-- wM_SETICON = 0x0080 :: WindowMessage
wM_GETICON = 0x007F :: WindowMessage

-- iCON_BIG = 1
-- iCON_SMALL = 0

in Terminal.hs, i.e. comment three lines.

new-user-name avatar Apr 11 '23 23:04 new-user-name