Skip to content

Commit adb1c7a

Browse files
committed
recomposition upon adjunction
1 parent 7bb948d commit adb1c7a

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

ocaml/typing/mode.ml

+4-2
Original file line numberDiff line numberDiff line change
@@ -1156,9 +1156,10 @@ module Lattices_mono = struct
11561156
| Max_with ax -> Proj (dst, ax)
11571157
| Compose (f, g) ->
11581158
let mid = src dst f in
1159+
let src = src mid g in
11591160
let f' = left_adjoint dst f in
11601161
let g' = left_adjoint mid g in
1161-
Compose (g', f')
1162+
compose src g' f'
11621163
| Join_with c -> Subtract c
11631164
| Meet_with _c ->
11641165
(* The downward closure of [Meet_with c]'s image is all [x <= c].
@@ -1186,9 +1187,10 @@ module Lattices_mono = struct
11861187
| Min_with ax -> Proj (dst, ax)
11871188
| Compose (f, g) ->
11881189
let mid = src dst f in
1190+
let src = src mid g in
11891191
let f' = right_adjoint dst f in
11901192
let g' = right_adjoint mid g in
1191-
Compose (g', f')
1193+
compose src g' f'
11921194
| Meet_with c -> Imply c
11931195
| Subtract c -> Join_with c
11941196
| Join_with _c ->

0 commit comments

Comments
 (0)