X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;ds=inline;f=helm%2Focaml%2Fmathql_interpreter%2Fmqint.ml;h=bee3bd765e4ba1efda37623e06cfd5751a023309;hb=49e52032242e39eba0cf24ca16a37c84b52cc356;hp=c67d11d15f655c6a38b6efea5dd9c12341b70b36;hpb=e5c9ea9efcc95afee3be91e8beb754c0cb4301dc;p=helm.git diff --git a/helm/ocaml/mathql_interpreter/mqint.ml b/helm/ocaml/mathql_interpreter/mqint.ml index c67d11d15..bee3bd765 100644 --- a/helm/ocaml/mathql_interpreter/mqint.ml +++ b/helm/ocaml/mathql_interpreter/mqint.ml @@ -123,16 +123,16 @@ let rec exec_set_exp c = function | MathQL.Relation (inv, rop, path, sexp, attl) -> let before = Sys.time() in if ! dbname = postgres_db then - (let res = relation_ex rop path (exec_set_exp c sexp) attl in + (let res = relation_ex inv rop path (exec_set_exp c sexp) attl in if ! stat then - (print_string ("RELATION " ^ (List.hd path) ^ " = " ^ string_of_int(List.length res) ^ ": "); + (print_string ("RELATION " ^ (fst path) ^ " = " ^ string_of_int(List.length res) ^ ": "); print_endline (string_of_float (Sys.time() -. before) ^ "s"); flush stdout); res) else - (let res = relation_galax_ex rop path (exec_set_exp c sexp) attl in + (let res = relation_galax_ex inv rop path (exec_set_exp c sexp) attl in if !stat then - (print_string ("RELATION-GALAX " ^ (List.hd path) ^ " = " ^ string_of_int(List.length res) ^ ": "); + (print_string ("RELATION-GALAX " ^ (fst path) ^ " = " ^ string_of_int(List.length res) ^ ": "); print_endline (string_of_float (Sys.time() -. before) ^ "s"); flush stdout); res) @@ -202,7 +202,7 @@ and exec_val_exp c = function else s::[] in edup ol - | MathQL.Record (rvar, vvar) -> List.assoc vvar (List.assoc rvar c.groups) + | MathQL.Record (rvar, path) -> List.assoc path (List.assoc rvar c.groups) | MathQL.VVar s -> List.assoc s c.vvars | MathQL.RefOf sexp -> List.map (fun (s,_) -> s) (exec_set_exp c sexp)