Custom Type Error not getting triggered in the nested Type function call

Hello, I have partial type function which is invoked by another type function. When the inner type function fails with TypeError, outer type function is not been able to propagate that type error to its caller. As a result of it, I'm getting following error • No instance for (KnownSymbol (NestedPartialTF (TypeError ...))) instead of • Unexpected type @ NestedPartialTF: Char Is this a bug? This behavior seems bit counter-intuitive as to work around, I had to write another (duplicate) type function at the top level to get the desired type error I'm using GHC-8 RC 3 and have attached complete src for reference. Regards, Magesh B

Hi,
yes, this looks like a bug. Could you please file a report on the
bug-tracker?
-Iavor
On Wed, Apr 27, 2016 at 9:43 AM, Magesh B
Hello,
I have partial type function which is invoked by another type function. When the inner type function fails with TypeError, outer type function is not been able to propagate that type error to its caller. As a result of it, I'm getting following error • No instance for (KnownSymbol (NestedPartialTF (TypeError ...))) instead of • Unexpected type @ NestedPartialTF: Char
Is this a bug? This behavior seems bit counter-intuitive as to work around, I had to write another (duplicate) type function at the top level to get the desired type error
I'm using GHC-8 RC 3 and have attached complete src for reference.
Regards, Magesh B
_______________________________________________ ghc-devs mailing list ghc-devs@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs
participants (2)
-
Iavor Diatchki
-
Magesh B