File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 77 module StateSet = Set. Make (Model )
88 module StateSetFP = Fixpoint. MakeSet (StateSet )
99
10-
10+ let f states =
11+ StateSet. elements states
12+ |> List. concat_map Model. step
13+ |> StateSet. of_list
1114
1215 (* * Tagastab kõik saavutatavad olekud. *)
1316 let all_states () : StateSet.t =
14- failwith " TODO "
17+ StateSetFP. closure_strict_distr f ( StateSet. singleton Model. initial)
1518
1619 (* * Tagastab kõik saavutatavad veaolekud.
1720 Vihje: StateSet.filter. *)
1821 let error_states () : StateSet.t =
19- failwith " TODO "
22+ StateSet. filter Model. is_error (all_states () )
2023
2124 (* * Kas mõni veaolek on saavutatav? *)
2225 let has_error () : bool =
23- failwith " TODO "
26+ not ( StateSet. is_empty (error_states () ))
2427
2528 (* * Kas veaolekud on mittesaavutatavad? *)
2629 let is_correct () : bool =
27- failwith " TODO "
30+ not (has_error () )
2831end
2932
3033
You can’t perform that action at this time.
0 commit comments