-tidy1 :: Id -- The Id being scrutinised
- -> TypecheckedPat -- The pattern against which it is to be matched
- -> MatchResult -- Current thing do do after matching
- -> DsM (TypecheckedPat, -- Equivalent pattern
- MatchResult) -- Augmented thing to do afterwards
- -- The augmentation usually takes the form
- -- of new bindings to be added to the front
+-------------------------------------------------------
+-- (pat', mr') = tidy1 v pat mr
+-- tidies the *outer level only* of pat, giving pat'
+-- It eliminates many pattern forms (as-patterns, variable patterns,
+-- list patterns, etc) yielding one of:
+-- WildPat
+-- ConPat
+-- LitPat
+-- NPat
+-- NPlusKPat
+--
+
+
+tidy1 :: Id -- The Id being scrutinised
+ -> TypecheckedPat -- The pattern against which it is to be matched
+ -> MatchResult -- Current thing do do after matching
+ -> DsM (TypecheckedPat, -- Equivalent pattern
+ MatchResult) -- Augmented thing to do afterwards
+ -- The augmentation usually takes the form
+ -- of new bindings to be added to the front