diff options
Diffstat (limited to 'compiler/deSugar/MatchLit.hs')
-rw-r--r-- | compiler/deSugar/MatchLit.hs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/deSugar/MatchLit.hs b/compiler/deSugar/MatchLit.hs index d99ae7e443..3bab8cf000 100644 --- a/compiler/deSugar/MatchLit.hs +++ b/compiler/deSugar/MatchLit.hs @@ -95,7 +95,7 @@ dsLit l = do HsString _ str -> mkStringExprFS str HsInteger _ i _ -> mkIntegerExpr i HsInt _ i -> return (mkIntExpr dflags (il_value i)) - XLit x -> pprPanic "dsLit" (ppr x) + XLit nec -> noExtCon nec HsRat _ (FL _ _ val) ty -> do num <- mkIntegerExpr (numerator val) denom <- mkIntegerExpr (denominator val) @@ -116,7 +116,7 @@ dsOverLit (OverLit { ol_val = val, ol_ext = OverLitTc rebindable ty case shortCutLit dflags val ty of Just expr | not rebindable -> dsExpr expr -- Note [Literal short cut] _ -> dsExpr witness -dsOverLit XOverLit{} = panic "dsOverLit" +dsOverLit (XOverLit nec) = noExtCon nec {- Note [Literal short cut] ~~~~~~~~~~~~~~~~~~~~~~~~ @@ -337,7 +337,7 @@ tidyLitPat (HsString src s) (mkNilPat charTy) (unpackFS s) -- The stringTy is the type of the whole pattern, not -- the type to instantiate (:) or [] with! -tidyLitPat lit = LitPat noExt lit +tidyLitPat lit = LitPat noExtField lit ---------------- tidyNPat :: HsOverLit GhcTc -> Maybe (SyntaxExpr GhcTc) -> SyntaxExpr GhcTc @@ -373,7 +373,7 @@ tidyNPat (OverLit (OverLitTc False ty) val _) mb_neg _eq outer_ty mk_con_pat :: DataCon -> HsLit GhcTc -> Pat GhcTc mk_con_pat con lit - = unLoc (mkPrefixConPat con [noLoc $ LitPat noExt lit] []) + = unLoc (mkPrefixConPat con [noLoc $ LitPat noExtField lit] []) mb_int_lit :: Maybe Integer mb_int_lit = case (mb_neg, val) of |