[Haskell-beginners] import question

Francesco Ariis fa-ml at ariis.it
Wed Feb 17 18:57:00 UTC 2021


Il 17 febbraio 2021 alle 11:13 Galaxy Being ha scritto:
> I'm trying to use Decimal but (I'm guessing) I don't know how to import it.
> 
> import Data.Decimal
> 
> dList :: [Decimal]
> dList = [1.1,1.2..2.0]
> 
> : <interactive>:70:11-17: error:
> :     Not in scope: type constructor or class `Decimal'

Works here. You need to add `Decimal` the dependencies of your project
or install it globally first
—F


More information about the Beginners mailing list