Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building with ghc 7.8.2 #28

Closed
ghost opened this issue Apr 25, 2014 · 2 comments
Closed

Building with ghc 7.8.2 #28

ghost opened this issue Apr 25, 2014 · 2 comments

Comments

@ghost
Copy link

ghost commented Apr 25, 2014

Building with ghc 7.8.2 doesn't work because custom instances of Typeable aren't allowed, and they are being used in src/MFlow/Forms/Widgets.hs.

After some digging, I found this commit:
b22651c
which fixes the problem, however the changes made by this commit seem to have been overwritten?

@agocorona
Copy link
Owner

Go to offending instance and remove the no ghc-7.8 code. It is
commented in preprocessor directives

Leave this:

data Medit view m a = Medit (M.Map B.ByteString [(String,View view m a)])
deriving Typeable

The code is:
data Medit view m a = Medit (M.Map B.ByteString [(String,View view m a)])
-- #ifdef GHC77
-- deriving Typeable
-- #else
instance (Typeable view, Typeable a) => Typeable (Medit view m a) where
typeOf= \v -> mkTyConApp (mkTyCon3 "MFlow" "MFlow.Forms.Widgets" "Medit" )
[typeOf (tview v)
,typeOf (ta v)]
where
tview :: Medit v m a -> v
tview= undefined
tm :: Medit v m a -> m a
tm= undefined
ta :: Medit v m a -> a
ta= undefined
-- #endif

2014-04-25 7:02 GMT+02:00, cyberia- notifications@github.com:

Building with ghc 7.8.2 doesn't work because custom instances of Typeable
aren't allowed, and they are being used in src/MFlow/Forms/Widgets.hs.

After some digging, I found this commit:
b22651c
which fixes the problem, however the changes made by this commit seem to
have been overwritten?


Reply to this email directly or view it on GitHub:
#28

Alberto.

@agocorona
Copy link
Owner

Solved with cpphs and CPP preprocessor directives in Widgets.hs

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

No branches or pull requests

1 participant