From 04296a25e1123f3e7240727f1e10142a1afadb7e Mon Sep 17 00:00:00 2001 From: Jim Pryor Date: Sat, 20 Nov 2010 12:45:22 -0500 Subject: [PATCH] assignment7 tweaks Signed-off-by: Jim Pryor --- hints/assignment_7_hint_6.mdwn | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hints/assignment_7_hint_6.mdwn b/hints/assignment_7_hint_6.mdwn index 0d9f02e8..d69c92e7 100644 --- a/hints/assignment_7_hint_6.mdwn +++ b/hints/assignment_7_hint_6.mdwn @@ -76,6 +76,8 @@ type clause = bool dpm -> bool dpm set;; +* More: + (* this generalizes the getx function from hint 4 *) let get (var : char) : entity dpm = fun (r, h) -> @@ -100,8 +102,6 @@ else bind_dpm entity1_dpm (fun e1 -> bind_dpm entity2_dpm (fun e2 -> unit_dpm (f e1 e2))) in fun one_dpm -> unit_set (bind_dpm one_dpm eliminator);; -  - let new_peg_and_assign (var_to_bind : char) (d : entity) : bool -> bool dpm = fun truth_value -> fun (r, h) -> @@ -119,6 +119,8 @@ (* include negate_op, and_op, or_op, and if_op as above *) +* More: + (* some handy utilities *) let (>>=) = bind_set;; let getx = get 'x';; -- 2.11.0