From 13ae8118913e5df9a8e8ff859cef8dd4bbcf8506 Mon Sep 17 00:00:00 2001 From: Roman Leshchinskiy Date: Mon, 16 Jul 2007 11:08:19 +0000 Subject: [PATCH] Pass correct dictionary to lengthPA for single-element environments --- compiler/vectorise/Vectorise.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/compiler/vectorise/Vectorise.hs b/compiler/vectorise/Vectorise.hs index c974c20..50e5923 100644 --- a/compiler/vectorise/Vectorise.hs +++ b/compiler/vectorise/Vectorise.hs @@ -398,8 +398,9 @@ mkClosureMonoFns info arg body bind_lenv lenv lbody lc_bndr [lbndr] = do lengthPA <- builtin lengthPAVar + pa_dict <- paDictOfType vty return . Let (NonRec lbndr lenv) - $ Case (mkApps (Var lengthPA) [Type vty, (Var lbndr)]) + $ Case (mkApps (Var lengthPA) [Type vty, pa_dict, (Var lbndr)]) lc_bndr (exprType lbody) [(DEFAULT, [], lbody)] -- 1.7.10.4