We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6fd0de5 commit 1c383b8Copy full SHA for 1c383b8
1 file changed
src/fixpoint/fixpoint.ml
@@ -8,7 +8,11 @@ module Make (D: sig type t [@@deriving eq] end) =
8
struct
9
(** Leiab funktsiooni püsipunkti alustades iteratsiooni antud väärtusest. *)
10
let rec fp (f: D.t -> D.t) (x: D.t): D.t =
11
- failwith "TODO"
+ let x' = f x in
12
+ if D.equal x x' then
13
+ x
14
+ else
15
+ fp f x'
16
end
17
18
(** Püsipunktid üle hulkade. *)
0 commit comments