[Haskell-cafe] How to expose if a constraint is satisfiable
anthony_clayden at clear.net.nz
Wed May 9 07:44:02 UTC 2018
Thanks David, Oliver, I'll leave it so Clinton whether that helps his use
I see the write-ups for both the Constraint Unions package and ifCxt
mentioned on the reddit thread talk about needing large amounts of
boilerplate. That is, an instance for each class and type that effectively
tells the class has an instance for that type. So that's the same as the
AdvancedOverlap I linked to -- from Oleg + SPJ.
IIUC, what Clinton's asking is: since there are already instances for `Show
Int`, `Ord Float`, etc (declared in the Prelude), why can't ghc 'just know'
that and expose it to type-level logic that can say: if there's `Show a` do
this, otherwise do that?
> On *Tue May 8 22:29:20 UTC 2018*, David Feuer wrote:
> Maybe look at https://www.reddit.com/r/haskell/comments/6k86je/constraint_unions_bringing_or_to_the_language_of/
> (relating to the repository Oliver links to) and note also Edward Kmett's response.
Eurrm. Could somebody explain that response using familiar language. I
think the `:-` operator might be referring to Edward's & David's
'constraints' package on github, for which I've asked if there's
Also asked if it'll be superseded by the 'Qualified Constraints' new
>> On Tue, May 8, 2018 at 9:52 AM, Oliver Charles <ollie at ocharles.org.uk <http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe>> wrote:
>>* I've only skimmed the thread, so sorry if this is a red herring, but could
*>>* this be helpful?*
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe