aboutsummaryrefslogtreecommitdiff
path: root/path/linePrinter.ml
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@chimrod.com>2021-01-01 11:08:38 +0100
committerSébastien Dailly <sebastien@chimrod.com>2021-01-01 11:08:38 +0100
commitaf88c8895bba85fe5340b34aafb3dce7650bd01f (patch)
treeee0c9d1bd463242c681c6202a9a57c8110d58f59 /path/linePrinter.ml
parente25b7797708c19cbaef68c14ebef8738de44c2d9 (diff)
Use first type module instead of functors
Diffstat (limited to 'path/linePrinter.ml')
-rwxr-xr-xpath/linePrinter.ml16
1 files changed, 8 insertions, 8 deletions
diff --git a/path/linePrinter.ml b/path/linePrinter.ml
index 247d554..e109e4a 100755
--- a/path/linePrinter.ml
+++ b/path/linePrinter.ml
@@ -2,19 +2,19 @@ module Repr = Layer.CanvaPrinter
type t = Point.t
-type 'a repr =
- { path: ('a Repr.t)
+type repr =
+ { path: (Repr.t)
}
let create_path
- : 'b -> 'a repr
+ : 'b -> repr
= fun _ ->
{ path = Repr.create ()
}
(* Start a new path. *)
let start
- : Point.t -> 'a repr -> 'a repr
+ : Point.t -> repr -> repr
= fun t {path} ->
let path = Repr.move_to (Point.get_coord t) path in
let path = Repr.line_to (Point.get_coord' t) path in
@@ -22,7 +22,7 @@ let start
}
let line_to
- : Point.t -> Point.t -> 'a repr -> 'a repr
+ : Point.t -> Point.t -> repr -> repr
= fun _ t {path} ->
let path = Repr.move_to (Point.get_coord t) path in
let path = Repr.line_to (Point.get_coord' t) path in
@@ -30,7 +30,7 @@ let line_to
}
let quadratic_to
- : Point.t -> Gg.v2 -> Gg.v2 -> Point.t -> 'a repr -> 'a repr
+ : Point.t -> Gg.v2 -> Gg.v2 -> Point.t -> repr -> repr
= fun _p0 _ctrl0 _ctrl1 p1 {path} ->
let path = Repr.move_to (Point.get_coord p1) path in
@@ -40,7 +40,7 @@ let quadratic_to
}
let stop
- : 'a repr -> 'a repr
+ : repr -> repr
= fun {path} ->
@@ -48,6 +48,6 @@ let stop
}
let get
- : 'a repr -> 'a Repr.t
+ : repr -> Repr.t
= fun {path; _} ->
path