whitespace cleanups, removed removal of warnings
This commit is contained in:
parent
82f99de39c
commit
2bd5d0eae3
2 changed files with 47 additions and 50 deletions
1
src/dune
1
src/dune
|
@ -2,5 +2,4 @@
|
||||||
(name opam_graph)
|
(name opam_graph)
|
||||||
(public_name opam-graph)
|
(public_name opam-graph)
|
||||||
(libraries opam-core opam-format dot rresult tyxml gg)
|
(libraries opam-core opam-format dot rresult tyxml gg)
|
||||||
(flags (:standard (-w -27-26)))
|
|
||||||
)
|
)
|
||||||
|
|
|
@ -80,7 +80,6 @@ let pp_graph ppf graph =
|
||||||
graph.nodes
|
graph.nodes
|
||||||
|
|
||||||
let dependencies ?(transitive=false) (switch : OpamFile.SwitchExport.t) =
|
let dependencies ?(transitive=false) (switch : OpamFile.SwitchExport.t) =
|
||||||
let available = switch.selections.sel_installed in
|
|
||||||
let root_pkg = root switch in
|
let root_pkg = root switch in
|
||||||
let top = root_pkg.OpamPackage.name in
|
let top = root_pkg.OpamPackage.name in
|
||||||
let graph = { top ; nodes = Name_map.empty } in
|
let graph = { top ; nodes = Name_map.empty } in
|
||||||
|
@ -431,7 +430,7 @@ svg {
|
||||||
let open Gg in
|
let open Gg in
|
||||||
let n_edges = float (max 1 n_edges) in
|
let n_edges = float (max 1 n_edges) in
|
||||||
let diff_angle = Float.two_pi /. n_edges in
|
let diff_angle = Float.two_pi /. n_edges in
|
||||||
let pos0, pos1 = V2.(v pos0.x pos0.y, v pos1.x pos1.y) in
|
let _pos0, pos1 = V2.(v pos0.x pos0.y, v pos1.x pos1.y) in
|
||||||
let center = V2.v center.x center.y in
|
let center = V2.v center.x center.y in
|
||||||
let pos1_rel = V2.(pos1 - center) in
|
let pos1_rel = V2.(pos1 - center) in
|
||||||
let height_triangle =
|
let height_triangle =
|
||||||
|
@ -462,7 +461,7 @@ svg {
|
||||||
let svg =
|
let svg =
|
||||||
deps_w_positions |> List.concat_map (fun ((dep, pos), layer2_deps) ->
|
deps_w_positions |> List.concat_map (fun ((dep, pos), layer2_deps) ->
|
||||||
let pos1 = pos in
|
let pos1 = pos in
|
||||||
let pos0, pos0_angle =
|
let pos0, _pos0_angle =
|
||||||
(*> Note: Need this because of mix of CSS selectors and SVG paint order*)
|
(*> Note: Need this because of mix of CSS selectors and SVG paint order*)
|
||||||
let center = V2.v center.x center.y in
|
let center = V2.v center.x center.y in
|
||||||
let pos1 = V2.v pos1.x pos1.y in
|
let pos1 = V2.v pos1.x pos1.y in
|
||||||
|
@ -555,7 +554,6 @@ svg {
|
||||||
|
|
||||||
let make_layer2_nodes_grid ~layer2_deps ~layer2_deps_center =
|
let make_layer2_nodes_grid ~layer2_deps ~layer2_deps_center =
|
||||||
let open Gg in
|
let open Gg in
|
||||||
let n_layer2_deps = List.length layer2_deps in
|
|
||||||
let dot_radius = 0.005 in
|
let dot_radius = 0.005 in
|
||||||
let cell_width = dot_radius *. 2.5 in
|
let cell_width = dot_radius *. 2.5 in
|
||||||
layer2_deps |> List.mapi (fun i layer2_dep ->
|
layer2_deps |> List.mapi (fun i layer2_dep ->
|
||||||
|
@ -564,7 +562,7 @@ svg {
|
||||||
let text = layer2_dep.name in
|
let text = layer2_dep.name in
|
||||||
let classes = [ layer2_dep.name; "layer2_dep" ] in
|
let classes = [ layer2_dep.name; "layer2_dep" ] in
|
||||||
let visual_svg = make_node ~pos ~radius:dot_radius ~text ~classes in
|
let visual_svg = make_node ~pos ~radius:dot_radius ~text ~classes in
|
||||||
let hitbox_svg =
|
let _hitbox_svg =
|
||||||
make_hitbox_square ~text ~classes
|
make_hitbox_square ~text ~classes
|
||||||
~center_pos:pos
|
~center_pos:pos
|
||||||
~width:cell_width in
|
~width:cell_width in
|
||||||
|
|
Loading…
Reference in a new issue