snapframework / snap

Top-level package for the official Snap Framework libraries, includes the snaplets API as well as infrastructure for sessions, auth, and templates.
http://snapframework.com/
BSD 3-Clause "New" or "Revised" License
455 stars 68 forks source link

Monad fail upgrade #216

Closed mightybyte closed 4 years ago

imalsogreg commented 4 years ago

Changing the test

rstFail :: Maybe Int
rstFail = evalRST (fail "foo") (0 :: Int) (0 :: Int)

to

rstFail :: Maybe Int
rstFail = evalRST (MonadFail.fail "foo") (0 :: Int) (0 :: Int)

fixes the test for ghc-8.6.5 (the only one I tested other than 8.8.2).

I'm puzzled why fail "foo" raises an exception when MonadFail.fail "foo" doesn't - still trying to figure that out.

mightybyte commented 4 years ago

@imalsogreg Thanks!