[Haskell-cafe] two type-level programming questions

2008-12-04 Thread Nicolas Frisby
1) Type families, associated types, synonyms... can anything replace
the use of TypeCast for explicit instance selection? Section 2, bullet
4 of http://www.haskell.org/haskellwiki/GHC/AdvancedOverlap indicates
a negative response. Any other ideas?

2) Any progress/options for kind polymorphism in instances?

Thanks for your time.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] two type-level programming questions

2008-12-04 Thread Ryan Ingram
Sort of.  I believe you can use type equality constraints to replace
the use of TypeCast; that is, in any code that looks like:

 instance TypeCast a HTrue = ...

you can write

 instance (a ~ HTrue) = ...

(at least, it has worked for me that way)

This at least makes me feel a bit more monadic (warm  fuzzy!) than
the indecipherable magic that is the declaration of
TypeCast/TypeCast'/TypeCast''

  -- ryan



On Thu, Dec 4, 2008 at 3:09 PM, Nicolas Frisby [EMAIL PROTECTED] wrote:
 1) Type families, associated types, synonyms... can anything replace
 the use of TypeCast for explicit instance selection? Section 2, bullet
 4 of http://www.haskell.org/haskellwiki/GHC/AdvancedOverlap indicates
 a negative response. Any other ideas?

 2) Any progress/options for kind polymorphism in instances?

 Thanks for your time.
 ___
 Haskell-Cafe mailing list
 Haskell-Cafe@haskell.org
 http://www.haskell.org/mailman/listinfo/haskell-cafe

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] two type-level programming questions

2008-12-04 Thread Jason Dusek
  More monadic?

--
_jsn
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] two type-level programming questions

2008-12-04 Thread Ryan Ingram
See slide 40 of Weaing the Hair Shirt: A Retrospective on Haskell,
Simon Peyton-Jones, POPL 2003
http://research.microsoft.com/Users/simonpj/papers/haskell-retrospective/index.htm

   -- ryan

On Thu, Dec 4, 2008 at 7:04 PM, Jason Dusek [EMAIL PROTECTED] wrote:
  More monadic?

 --
 _jsn

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe