[Haskell-beginners] What's wrong with Haddock?!

Francesco Ariis fa-ml at ariis.it
Thu Oct 26 11:34:38 UTC 2017


On Thu, Oct 26, 2017 at 02:11:10PM +0300, Baa wrote:
> @Francesco Ariis:
> 
>   instance Conversion UTCTime where
>     aspS a = round $ 1E12 * utcTimeToPOSIXSeconds a -- ^as time period from 1970-1-1
>     frompS a = posixSecondsToUTCTime $ fromInteger $ (round $ d/1E12) -- ^from time period from 1970-1-1
>       where d = fromInteger a :: Double

-- ^ is meant to be put after a function *declaration* iirc. Try to
add signatures to your instance as

    instance Foo Bar where
        fa :: Int -> a    -- ^ some comment
        fa x = undefined
        fb :: String -> a    -- ^ some more comment
        fb x = undefined

and let us know if it fixed the problem.


More information about the Beginners mailing list