From df4e13fc6f98ac689238ba325c7b276bbd8e568c Mon Sep 17 00:00:00 2001 From: sof Date: Thu, 21 Jan 1999 20:00:55 +0000 Subject: [PATCH] [project @ 1999-01-21 20:00:55 by sof] dsExpr: make sure special case for unboxed tuple patterns only 'fire' when the tup. pat. is unboxed. --- ghc/compiler/deSugar/DsExpr.lhs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ghc/compiler/deSugar/DsExpr.lhs b/ghc/compiler/deSugar/DsExpr.lhs index afdf166..622b4ef 100644 --- a/ghc/compiler/deSugar/DsExpr.lhs +++ b/ghc/compiler/deSugar/DsExpr.lhs @@ -306,10 +306,10 @@ dsExpr (HsSCC cc expr) getModuleAndGroupDs `thenDs` \ (mod_name, group_name) -> returnDs (Note (SCC (mkUserCC cc mod_name group_name)) core_expr) --- special case to handle unboxed tuple patterns +-- special case to handle unboxed tuple patterns. dsExpr (HsCase discrim matches@[Match _ [TuplePat ps boxed] _ _] src_loc) - | all var_pat ps + | not boxed && all var_pat ps = putSrcLocDs src_loc $ dsExpr discrim `thenDs` \ core_discrim -> matchWrapper CaseMatch matches "case" `thenDs` \ ([discrim_var], matching_code) -> -- 1.7.10.4