diff options
author | Benjamin Barenblat <bbaren@mit.edu> | 2016-02-13 10:41:17 -0500 |
---|---|---|
committer | Benjamin Barenblat <bbaren@mit.edu> | 2016-02-13 10:41:17 -0500 |
commit | 5ca6148aaf7b930a8868d0543f1a307d40532243 (patch) | |
tree | 55ec538c5bdef601b0ac8ebca71ad495f644326d /src/reduce_local.sml | |
parent | 3d3886672433f0775f772d8d2ee47c5f5e0bc745 (diff) | |
parent | 3044fbedd58961f8c1168eb3bc2eeeb8a2b0b60e (diff) |
Merge branch 'upstream' into dfsg_clean20160213+dfsg
Diffstat (limited to 'src/reduce_local.sml')
-rw-r--r-- | src/reduce_local.sml | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/reduce_local.sml b/src/reduce_local.sml index 6fbc6a96..06f49fef 100644 --- a/src/reduce_local.sml +++ b/src/reduce_local.sml @@ -62,8 +62,7 @@ fun match (env, p : pat, e : exp) = fun match (env, p, e) = case (#1 p, #1 e) of - (PWild, _) => Yes env - | (PVar (x, t), _) => Yes (Known (multiLiftExpInExp (length env - baseline) e) :: env) + (PVar (x, t), _) => Yes (Known (multiLiftExpInExp (length env - baseline) e) :: env) | (PPrim p, EPrim p') => if Prim.equal (p, p') then @@ -313,8 +312,7 @@ fun exp env (all as (e, loc)) = fun patBinds (p, _) = case p of - PWild => 0 - | PVar _ => 1 + PVar _ => 1 | PPrim _ => 0 | PCon (_, _, _, NONE) => 0 | PCon (_, _, _, SOME p) => patBinds p @@ -322,8 +320,7 @@ fun exp env (all as (e, loc)) = fun pat (all as (p, loc)) = case p of - PWild => all - | PVar (x, t) => (PVar (x, con env t), loc) + PVar (x, t) => (PVar (x, con env t), loc) | PPrim _ => all | PCon (dk, pc, cs, po) => (PCon (dk, patCon pc, map (con env) cs, Option.map pat po), loc) |