Skip to content

Use Prelude.elem explicitly in FFI.hs#710

Merged
dmjio merged 1 commit intomasterfrom
explicit-elem
Sep 9, 2022
Merged

Use Prelude.elem explicitly in FFI.hs#710
dmjio merged 1 commit intomasterfrom
explicit-elem

Conversation

@dmjio
Copy link
Owner

@dmjio dmjio commented Sep 9, 2022

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

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
Copy link
Owner Author

dmjio commented Sep 9, 2022

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

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

@dmjio dmjio merged commit 82a7f3f into master Sep 9, 2022
@dmjio dmjio deleted the explicit-elem branch September 9, 2022 00:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant