equal
deleted
inserted
replaced
341 val patts1 = map (fn (_,tag,[pat]) => (pat,tag)) patts |
341 val patts1 = map (fn (_,tag,[pat]) => (pat,tag)) patts |
342 handle Match => mk_functional_err "error in pattern-match translation" |
342 handle Match => mk_functional_err "error in pattern-match translation" |
343 val patts2 = Library.sort (Library.int_ord o Library.pairself row_of_pat) patts1 |
343 val patts2 = Library.sort (Library.int_ord o Library.pairself row_of_pat) patts1 |
344 val finals = map row_of_pat patts2 |
344 val finals = map row_of_pat patts2 |
345 val originals = map (row_of_pat o #2) rows |
345 val originals = map (row_of_pat o #2) rows |
346 val dummy = case (originals\\finals) |
346 val dummy = case (subtract (op =) finals originals) |
347 of [] => () |
347 of [] => () |
348 | L => mk_functional_err |
348 | L => mk_functional_err |
349 ("The following clauses are redundant (covered by preceding clauses): " ^ |
349 ("The following clauses are redundant (covered by preceding clauses): " ^ |
350 commas (map (fn i => Int.toString (i + 1)) L)) |
350 commas (map (fn i => Int.toString (i + 1)) L)) |
351 in {functional = Abs(Long_Name.base_name fname, ftype, |
351 in {functional = Abs(Long_Name.base_name fname, ftype, |