Skip to content

Commit 670cc27

Browse files
committed
Demand: Introduce DemandEqIncrSolverFromDemandEqSolver
1 parent 315bd09 commit 670cc27

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

src/solver/postSolver.ml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,3 +349,21 @@ module DemandEqIncrSolverFromEqSolver (Sol: GenericEqSolver): DemandEqIncrSolver
349349
Post.post xs vs vh;
350350
(vh, ())
351351
end
352+
353+
354+
module DemandEqIncrSolverFromDemandEqSolver (Sol: DemandEqSolver): DemandEqIncrSolver =
355+
functor (Arg: IncrSolverArg) (S: DemandEqConstrSys) (VH: Hashtbl.S with type key = S.v) ->
356+
struct
357+
module EqSys = EqConstrSysFromDemandConstrSys (S)
358+
module Sol = Sol (S) (VH)
359+
module Post = MakeList (ListArgFromStdArg (EqSys) (VH) (Arg))
360+
361+
type marshal = unit
362+
let copy_marshal () = ()
363+
let relift_marshal () = ()
364+
365+
let solve xs vs _ =
366+
let vh = Sol.solve xs vs in
367+
Post.post xs vs vh;
368+
(vh, ())
369+
end

0 commit comments

Comments
 (0)