Open turion opened 6 years ago
As a benchmark, try to get the following to compile with as few constraints as possible:
rhine1 :: Rhine m cl1 a b
rhine1 = undefined
rhine2 :: Rhine m cl1 a b
rhine2 = undefined
schedule :: Schedule m cl1 cl2
schedule = undefined
parRhine
:: (Time cl1 ~ Time (Out cl1), Time cl2 ~ Time (Out cl2), Time cl1 ~ Time (In cl1), Time cl2 ~ Time (In cl2), Time cl1 ~ Time cl2, Clock m cl1, Clock m cl2)
=> Rhine m (ParClock m cl1 cl2) a b
parRhine = rhine1 **@ schedule @** rhine2
Another kind of constraints are all the GetClockProxy
constraints, introduced in #140.
Right now, many combinators like
**@ @**
etc. require a lot of constraints on clock types, especially on their time domains. It would be great if those could be hidden, maybe via GADTs or in the type classes, in the reusable components, i.e.Schedule
s,ResamplingBuffer
s and so on.