From: Matthijs Kooijman Date: Mon, 22 Jun 2009 12:23:58 +0000 (+0200) Subject: Add error message to mkConcSm for unsupported expressions. X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;ds=sidebyside;h=81bbc7b720fe914d5655bd6a125925d54a62c5af;hp=-c;p=matthijs%2Fmaster-project%2Fc%CE%BBash.git Add error message to mkConcSm for unsupported expressions. Previously, there was only a cryptic message from ghc, now it also mentions the unsupported expression. --- 81bbc7b720fe914d5655bd6a125925d54a62c5af diff --git a/VHDL.hs b/VHDL.hs index 229ba5c..a450c04 100644 --- a/VHDL.hs +++ b/VHDL.hs @@ -350,6 +350,7 @@ mkConcSm (bndr, (Case (Var scrut) b ty [(_, _, Var false), (con, _, Var true)])) return $ mkCondAssign (Left bndr) cond_expr true_expr false_expr mkConcSm (_, (Case (Var _) _ _ alts)) = error "VHDL.mkConcSm Not in normal form: Case statement with more than two alternatives" mkConcSm (_, Case _ _ _ _) = error "VHDL.mkConcSm Not in normal form: Case statement has does not have a simple variable as scrutinee" +mkConcSm (bndr, expr) = error $ "VHDL.mkConcSM Unsupported binding in let expression: " ++ pprString bndr ++ " = " ++ pprString expr -- Create an unconditional assignment statement mkUncondAssign ::