fact: Definition open_pattern@{a p+} {A : Type@{a}} {P : A -> Type@{p}} {y} (E : Exception) := Eval lazy beta iota match zeta delta [meq_sym] in fix open_pattern (p : Mpattern A P) : t (P y) := match p with | pany f => f y | pbase x f u => bind@{a _} (unify x y u) (fun oeq => match oeq return t (P y) with | mSome eq => let 'meq_refl := eq in let b := (f) in b | mNone => raise E end) | ptele f => e <- evar@{_ a} _; open_pattern (f e) | psort f => mtry' (open_pattern (f Propₛ)) (fun e => M.unify_cnt (B:=fun _ => (P y)) UniMatchNoRed e E (open_pattern (f Typeₛ)) (raise e) ) end.
imports: Strings.String NArith.BinNat Mtac2(Logic Datatypes Logic List Utils MTele Pattern Specif)