X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Focaml%2Fmathql_interpreter%2Fmqint.ml;h=cf453c6f61b7d82b0424160ba119d226cbd8d52f;hb=b539c22c2f70f165beb439c98a41cb63971c51a4;hp=5fbfc86c6665df1e34f5588e27895763851004ff;hpb=f22ab48f16bbebd949368ae20574c80d757b1698;p=helm.git diff --git a/helm/ocaml/mathql_interpreter/mqint.ml b/helm/ocaml/mathql_interpreter/mqint.ml index 5fbfc86c6..cf453c6f6 100644 --- a/helm/ocaml/mathql_interpreter/mqint.ml +++ b/helm/ocaml/mathql_interpreter/mqint.ml @@ -92,13 +92,6 @@ let get_prop_id prop = else List.assoc prop (match !prop_pool with Some l -> l | _ -> assert false) ;; -(* automatically performes the union of a given list of patterns *) -let rec pattern_list_ex = function - | [] -> [] - | [(apreamble, apattern, afragid)] -> pattern_ex (apreamble, apattern, afragid) - | (apreamble, apattern, afragid) :: tail -> - union_ex (pattern_ex (apreamble, apattern, afragid)) (pattern_list_ex tail) - (* execute_ex env q *) (* [env] is the attributed uri environment in which the query [q] *) (* must be evaluated *) @@ -112,8 +105,8 @@ let rec execute_ex env = use_ex (execute_ex env alist) asvar (get_prop_id "refObj") (* "F" (*"refObj"*) *) | MQUse (alist, asvar) -> use_ex (execute_ex env alist) asvar (get_prop_id "backPointer") (* "B" (*"backPointer"*) *) - | MQPattern l -> - pattern_list_ex l + | MQPattern (apreamble, apattern, afragid) -> + pattern_ex (apreamble, apattern, afragid) | MQUnion (l1, l2) -> union_ex (execute_ex env l1) (execute_ex env l2) | MQDiff (l1, l2) ->