Commit 00395767 authored by bguillaum's avatar bguillaum

rename grew_types -> libgrew_types

git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/semagramme/libcaml-grew/trunk@8443 7838e531-6607-4d57-9587-6c381814729c
parent 1502540b
......@@ -3,7 +3,7 @@ PRE_FILES_DEP = libgrew_utils grew_ast
PRE_FILES_CMO = $(PRE_FILES_DEP:%=%.cmo)
PRE_FILES_CMX = $(PRE_FILES_DEP:%=%.cmx)
POST_FILES_DEP = grew_fs grew_edge grew_node grew_graph grew_types grew_command grew_rule grew_grs grew_html
POST_FILES_DEP = grew_fs grew_edge grew_node grew_graph libgrew_types grew_command grew_rule grew_grs grew_html
POST_FILES_CMO = $(POST_FILES_DEP:%=%.cmo)
POST_FILES_CMX = $(POST_FILES_DEP:%=%.cmx)
......@@ -59,7 +59,7 @@ parser_byte:
# librairie
libgrew.mli : grew_types.mli libgrew_.mli
libgrew.mli : libgrew_types.mli libgrew_.mli
rm -rf libgrew.mli
touch libgrew.mli
echo "(** Grew Library" > libgrew.mli
......@@ -68,7 +68,7 @@ libgrew.mli : grew_types.mli libgrew_.mli
echo "@version 1.0.0" >> libgrew.mli
echo "*)" >> libgrew.mli
echo "" >> libgrew.mli
cat grew_types.mli >> libgrew.mli
cat libgrew_types.mli >> libgrew.mli
echo "" >> libgrew.mli
echo "" >> libgrew.mli
cat libgrew_.mli >> libgrew.mli
......@@ -94,7 +94,7 @@ endif
DEPENDS_DIR= -I parser
###### grew_core.ml ##############################################################
GREW_CORE_DEP = grew_types
GREW_CORE_DEP = libgrew_types
GREW_CORE_CMI = $(GREW_CORE_DEP:%=%.cmi)
GREW_CORE_CMO = $(GREW_CORE_DEP:%=%.cmo)
GREW_CORE_CMX = $(GREW_CORE_DEP:%=%.cmx)
......@@ -227,20 +227,20 @@ grew_graph.cmx: $(GREW_GRAPH_CMX) grew_graph.cmi grew_graph.ml
################################################################################
###### grew_types.ml ##############################################################
GREW_TYPES_DEP = grew_graph
GREW_TYPES_CMI = $(GREW_TYPES_DEP:%=%.cmi)
GREW_TYPES_CMO = $(GREW_TYPES_DEP:%=%.cmo)
GREW_TYPES_CMX = $(GREW_TYPES_DEP:%=%.cmx)
###### libgrew_types.ml ##############################################################
LIBGREW_TYPES_DEP = grew_graph
LIBGREW_TYPES_CMI = $(LIBGREW_TYPES_DEP:%=%.cmi)
LIBGREW_TYPES_CMO = $(LIBGREW_TYPES_DEP:%=%.cmo)
LIBGREW_TYPES_CMX = $(LIBGREW_TYPES_DEP:%=%.cmx)
grew_types.cmi: $(GREW_TYPES_CMI) grew_types.mli
$(OCAMLC) -c grew_types.mli
libgrew_types.cmi: $(LIBGREW_TYPES_CMI) libgrew_types.mli
$(OCAMLC) -c libgrew_types.mli
grew_types.cmo: $(GREW_TYPES_CMO) grew_types.cmi grew_types.ml
$(OCAMLC) $(BYTE_FLAGS) -c $(DEPENDS_DIR) grew_types.ml
libgrew_types.cmo: $(LIBGREW_TYPES_CMO) libgrew_types.cmi libgrew_types.ml
$(OCAMLC) $(BYTE_FLAGS) -c $(DEPENDS_DIR) libgrew_types.ml
grew_types.cmx: $(GREW_TYPES_CMX) grew_types.cmi grew_types.ml
$(OCAMLOPT) $(OPT_FLAGS) -c $(DEPENDS_DIR) grew_types.ml
libgrew_types.cmx: $(LIBGREW_TYPES_CMX) libgrew_types.cmi libgrew_types.ml
$(OCAMLOPT) $(OPT_FLAGS) -c $(DEPENDS_DIR) libgrew_types.ml
################################################################################
......@@ -262,7 +262,7 @@ grew_command.cmx: $(GREW_COMMAND_CMX) grew_command.cmi grew_command.ml
###### grew_rule.ml ##############################################################
GREW_RULE_DEP = libgrew_utils grew_ast grew_command grew_edge grew_fs grew_node grew_types grew_graph
GREW_RULE_DEP = libgrew_utils grew_ast grew_command grew_edge grew_fs grew_node libgrew_types grew_graph
GREW_RULE_CMI = $(GREW_RULE_DEP:%=%.cmi)
GREW_RULE_CMO = $(GREW_RULE_DEP:%=%.cmo)
GREW_RULE_CMX = $(GREW_RULE_DEP:%=%.cmx)
......@@ -287,7 +287,7 @@ endif
###### grew_grs.ml ##############################################################
GREW_GRS_DEP = libgrew_utils grew_edge grew_types grew_graph grew_rule
GREW_GRS_DEP = libgrew_utils grew_edge libgrew_types grew_graph grew_rule
GREW_GRS_CMI = $(GREW_GRS_DEP:%=%.cmi)
GREW_GRS_CMO = $(GREW_GRS_DEP:%=%.cmo)
GREW_GRS_CMX = $(GREW_GRS_DEP:%=%.cmx)
......
......@@ -292,7 +292,7 @@ module Grs = struct
let rec loop instance module_list =
let instance = {instance with Instance.graph = G_graph.normalize instance.Instance.graph} in
match module_list with
| [] -> Grew_types.Leaf instance.Instance.graph
| [] -> Libgrew_types.Leaf instance.Instance.graph
| next :: tail ->
let (good_set, bad_set) =
Rule.normalize
......@@ -306,8 +306,8 @@ module Grs = struct
match inst_list with
| [{Instance.big_step = None}] ->
Grew_types.Local_normal_form (instance.Instance.graph, next.Modul.name, loop instance tail)
| _ -> Grew_types.Node
Libgrew_types.Local_normal_form (instance.Instance.graph, next.Modul.name, loop instance tail)
| _ -> Libgrew_types.Node
(
instance.Instance.graph,
next.Modul.name,
......
......@@ -89,7 +89,7 @@ module Grs: sig
val rewrite: t -> string -> Instance.t -> Rewrite_history.t
(* only externeal strucutre is returned, each edge contains a "dummy" big_step *)
val build_rew_display: t -> string -> Instance.t -> Grew_types.rew_display
val build_rew_display: t -> string -> Instance.t -> Libgrew_types.rew_display
val rule_iter: (string -> Rule.t -> unit) -> t -> unit
val filter_iter: (string -> Rule.t -> unit) -> t -> unit
......
......@@ -25,7 +25,7 @@ module Instance = struct
graph: G_graph.t;
history: Command.h list;
rules: string list;
big_step: Grew_types.big_step option;
big_step: Libgrew_types.big_step option;
free_index: int;
activated_node: Gid.t list;
}
......@@ -41,7 +41,7 @@ module Instance = struct
let rev_steps t =
{ t with big_step = match t.big_step with
| None -> None
| Some bs -> Some {bs with Grew_types.small_step = List.rev bs.Grew_types.small_step }
| Some bs -> Some {bs with Libgrew_types.small_step = List.rev bs.Libgrew_types.small_step }
}
let flatten t =
......@@ -755,7 +755,7 @@ module Rule = struct
rule.commands in
let rule_app = {
Grew_types.rule_name = rule.name;
Libgrew_types.rule_name = rule.name;
up = up_deco rule matching;
down = down_deco (matching,created_nodes) rule.commands
} in
......@@ -763,8 +763,8 @@ module Rule = struct
{new_instance with
Instance.rules = rule.name :: new_instance.Instance.rules;
big_step = match new_instance.Instance.big_step with
| None -> Some { Grew_types.first = rule_app; small_step = [] }
| Some bs -> Some { bs with Grew_types.small_step = (instance.Instance.graph, rule_app) :: bs.Grew_types.small_step }
| None -> Some { Libgrew_types.first = rule_app; small_step = [] }
| Some bs -> Some { bs with Libgrew_types.small_step = (instance.Instance.graph, rule_app) :: bs.Libgrew_types.small_step }
}
(*-----------------------------*)
......
......@@ -21,7 +21,7 @@ module Instance : sig
graph: G_graph.t;
history: Command.h list;
rules: string list;
big_step: Grew_types.big_step option;
big_step: Libgrew_types.big_step option;
free_index: int;
activated_node: Gid.t list;
}
......
......@@ -8,7 +8,7 @@
(* Authors: see AUTHORS file *)
(**********************************************************************************)
include Grew_types
include Libgrew_types
open Printf
open Log
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment