Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /smlnj-lib/trunk/RegExp/BackEnd/thompson-engine.sml
ViewVC logotype

Diff of /smlnj-lib/trunk/RegExp/BackEnd/thompson-engine.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3015, Sun May 4 22:00:33 2008 UTC revision 3016, Mon May 5 16:41:33 2008 UTC
# Line 83  Line 83 
83          (* compile an RE *)          (* compile an RE *)
84            fun reComp re = (case re            fun reComp re = (case re
85                   of RE.Group re => reComp re                   of RE.Group re => reComp re
86                      | RE.Alt[] => raise Fail "empty alternative"
87                    | RE.Alt[re] => reComp re                    | RE.Alt[re] => reComp re
88                    | RE.Alt(re::rest) =>  let                    | RE.Alt(re::rest) =>  let
89                        val f1 = reComp re                        val f1 = reComp re
# Line 91  Line 92 
92                        in                        in
93                          {start = s, out = #out f1 @ #out f2}                          {start = s, out = #out f1 @ #out f2}
94                        end                        end
95                      | RE.Concat[] => raise Fail "empty concatenation"
96                    | RE.Concat[re] => reComp re                    | RE.Concat[re] => reComp re
97                    | RE.Concat(re::rest) => let                    | RE.Concat(re::rest) => let
98                        val f1 = reComp re                        val f1 = reComp re

Legend:
Removed from v.3015  
changed lines
  Added in v.3016

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0