From b96badda2ed8fa2bfcb06c8cd853e022b05c8625 Mon Sep 17 00:00:00 2001 From: Dan Doel Date: Thu, 18 Jun 2020 14:59:05 -0400 Subject: [PATCH] Prepare UnboundP as VarP once more - This was a mistaken attempt to fix the default case in some situations, but it has been fixed in other ways now, and interacts inappropriately with some other pattern compilation code. --- parser-typechecker/src/Unison/Runtime/Pattern.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parser-typechecker/src/Unison/Runtime/Pattern.hs b/parser-typechecker/src/Unison/Runtime/Pattern.hs index 676913844..91b057e98 100644 --- a/parser-typechecker/src/Unison/Runtime/Pattern.hs +++ b/parser-typechecker/src/Unison/Runtime/Pattern.hs @@ -240,7 +240,7 @@ prepareAs (SequenceOpP _ p op q) u = do prepareAs p u = pure $ u <$ p preparePattern :: Var v => PatternP a -> PPM v (PatternV v) -preparePattern (UnboundP _) = UnboundP <$> freshVar +preparePattern (UnboundP _) = VarP <$> freshVar preparePattern (VarP _) = VarP <$> useVar preparePattern (AsP _ p) = prepareAs p =<< useVar preparePattern p = prepareAs p =<< freshVar