dmjio / miso

:ramen: A tasty Haskell front-end framework
https://haskell-miso.org
BSD 3-Clause "New" or "Revised" License
2.19k stars 139 forks source link

Use Prelude.elem explicitly in FFI.hs #710

Closed dmjio closed 2 years ago

dmjio commented 2 years ago

Despite the fact elem is being hidden, GHC 9.0.2 is upset.

src/Miso/FFI.hs:95:35: error:
    Ambiguous occurrence 'elem'
    It could refer to
       either 'Prelude.elem',
              imported from 'Prelude' at src/Miso/FFI.hs:14:8-15
              (and originally defined in 'Data.Foldable')
           or 'Miso.String.elem',
              imported from 'Miso.String' at src/Miso/FFI.hs:67:1-28
              (and originally defined in 'Data.Text')
   |
95 |   classSet <- ((JSS.pack "class") `elem`) <$> listProps obj
dmjio commented 2 years ago

Yes, it is indeed hidden, and GHC is still complaining.

https://github.com/dmjio/miso/blob/master/src/Miso/FFI.hs#L67