@@ -58,8 +58,8 @@ let pp_err e : (string, err) Result.t =
5858  match  e with 
5959  |  ExpectError  (x , e , Func ((Null, f ), [] )) when  equal_string f " default" 
6060    sprintf " %s:\n * expected: %s\n * got: %s\n " " Expect Error" 
61-       (e |>  remove_mark_all  |>  string_of_constellation)
62-       (x |>  remove_mark_all  |>  string_of_constellation)
61+       (e |>  Marked. remove_all  |>  string_of_constellation)
62+       (x |>  Marked. remove_all  |>  string_of_constellation)
6363    |>  Result. return
6464  |  ExpectError  (_x , _e , Func ((Null, f ), [ t  ])) when  equal_string f " error" 
6565    sprintf " %s: %s\n " " Expect Error" |>  Result. return
@@ -70,7 +70,7 @@ let pp_err e : (string, err) Result.t =
7070    |>  Result. return
7171
7272let  rec  eval_sgen_expr  (env  : env ) :
73-   sgen_expr  -> (marked_constellation , err ) Result. t  =  function 
73+   sgen_expr  -> (Marked. constellation , err ) Result. t  =  function 
7474  |  Raw  mcs  -> Ok  mcs
7575  |  Id  x  -> begin 
7676    match  get_obj env x with 
@@ -88,43 +88,43 @@ let rec eval_sgen_expr (env : env) :
8888    Ok  (List. concat mcs)
8989  |  Exec  (b , e ) ->
9090    let *  eval_e =  eval_sgen_expr env e in 
91-     Ok  (exec ~linear: b eval_e |>  unmark_all )
91+     Ok  (exec ~linear: b eval_e |>  Marked. make_action_all )
9292  |  Focus  e  ->
9393    let *  eval_e =  eval_sgen_expr env e in 
94-     eval_e |>  remove_mark_all  |>  focus  |>  Result. return
94+     eval_e |>  Marked. remove_all  |>  Marked. make_state_all  |>  Result. return
9595  |  Kill  e  ->
9696    let *  eval_e =  eval_sgen_expr env e in 
97-     eval_e |>  remove_mark_all  |>  kill |>  focus  |>  Result. return
97+     eval_e |>  Marked. remove_all  |>  kill |>  Marked. make_state_all  |>  Result. return
9898  |  Clean  e  ->
9999    let *  eval_e =  eval_sgen_expr env e in 
100-     eval_e |>  remove_mark_all  |>  clean |>  focus  |>  Result. return
100+     eval_e |>  Marked. remove_all  |>  clean |>  Marked. make_state_all  |>  Result. return
101101  |  Process  []  -> Ok  [] 
102102  |  Process  (h  :: t ) ->
103103    let *  eval_e =  eval_sgen_expr env h in 
104-     let  init =  eval_e |>  remove_mark_all  |>  focus  in 
104+     let  init =  eval_e |>  Marked. remove_all  |>  Marked. make_state_all  in 
105105    let *  res = 
106106      List. fold_left t ~init: (Ok  init) ~f: (fun  acc  x  ->
107107        let *  acc =  acc in 
108108        match  x with 
109109        |  Id  (Func ((Null, "&kill" ), [] )) ->
110-           acc |>  remove_mark_all  |>  kill |>  focus  |>  Result. return
110+           acc |>  Marked. remove_all  |>  kill |>  Marked. make_state_all  |>  Result. return
111111        |  Id  (Func ((Null, "&clean" ), [] )) ->
112-           acc |>  remove_mark_all  |>  clean |>  focus  |>  Result. return
112+           acc |>  Marked. remove_all  |>  clean |>  Marked. make_state_all  |>  Result. return
113113        |  _  ->
114-           let  origin =  acc |>  remove_mark_all  |>  focus  in 
114+           let  origin =  acc |>  Marked. remove_all  |>  Marked. make_state_all  in 
115115          eval_sgen_expr env (Focus  (Exec  (false , Group  [ x; Raw  origin ]))) )
116116    in 
117117    res |>  Result. return
118118  |  Eval  e  -> (
119119    let *  eval_e =  eval_sgen_expr env e in 
120120    match  eval_e with 
121-     |  [ Marked  { content =  [ r ]; bans =  _ } ]
122-     |  [ Unmarked  { content =  [ r ]; bans =  _ } ] ->
121+     |  [ State  { content =  [ r ]; bans =  _ } ]
122+     |  [ Action  { content =  [ r ]; bans =  _ } ] ->
123123      r |>  expr_of_ray |>  Expr. sgen_expr_of_expr |>  eval_sgen_expr env
124124    |  e  ->
125125      failwith
126126        ( " eval error: " 
127-         ^  string_of_constellation (remove_mark_all  e)
127+         ^  string_of_constellation (Marked. remove_all  e)
128128        ^  "  is not a ray." 
129129
130130and  expr_of_ray  =  function 
@@ -139,13 +139,13 @@ let rec eval_decl env : declaration -> (env, err) Result.t = function
139139    let  env =  { objs =  add_obj env x e } in 
140140    Ok  env
141141  |  Show  (Raw mcs ) ->
142-     mcs |>  remove_mark_all  |>  string_of_constellation |>  Stdlib. print_string;
142+     mcs |>  Marked. remove_all  |>  string_of_constellation |>  Stdlib. print_string;
143143    Stdlib. print_newline () ;
144144    Stdlib. flush Stdlib. stdout;
145145    Ok  env
146146  |  Show  e  ->
147147    let *  eval_e =  eval_sgen_expr env e in 
148-     List. map eval_e ~f: remove_mark 
148+     List. map eval_e ~f: Marked. remove 
149149    |>  string_of_constellation |>  Stdlib. print_string;
150150    Stdlib. print_newline () ;
151151    Ok  env
@@ -155,8 +155,7 @@ let rec eval_decl env : declaration -> (env, err) Result.t = function
155155  |  Expect  (e1 , e2 , message ) ->
156156    let *  eval_e1 =  eval_sgen_expr env e1 in 
157157    let *  eval_e2 =  eval_sgen_expr env e2 in 
158-     let  normalize  x  =  x |>  remove_mark_all |>  unmark_all in 
159-     if  not  @@  equal_marked_constellation (normalize eval_e1) (normalize eval_e2)
158+     if  not  @@  Marked. equal_constellation (Marked. normalize_all eval_e1) (Marked. normalize_all eval_e2)
160159    then  Error  (ExpectError  (eval_e1, eval_e2, message))
161160    else  Ok  env
162161  |  Use  path  ->
0 commit comments