<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 3, 2020, at 4:40 AM, Alejandro Serrano Mena <<a href="mailto:trupill@gmail.com" class="">trupill@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">- GADTs:</div><div dir="ltr" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">  - Stable and well documented,</div><div dir="ltr" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">  - Adding indices to types is one of the main reasons one would like to have MultiParamTypeClasses and TypeFamilies on,</div><div dir="ltr" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">  - I find the GADT syntax much nicer (but this is an extremely personal choice.)</div></div></blockquote></div><br class=""><div class="">I voted against GADTs and am not yet inspired to change that vote: GADTs cause trouble for type inference. For example:</div><div class=""><br class=""></div><div class=""></div><blockquote type="cite" class=""><div class="">data T a where</div><div class="">  MkT :: Int -> T a</div><div class=""><br class=""></div><div class="">foo (MkT x) = x</div></blockquote><div class=""><br class=""></div><div class="">GHC can infer that foo :: T a -> Int.</div><div class=""><br class=""></div><div class="">But if I change this to</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class=""><div class="">data T a where</div><div class="">  MkT :: Int -> T Int</div><div class=""><br class=""></div><div class="">foo (MkT x) = x</div></blockquote><br class=""></div><div class="">(where T is now a GADT) GHC can no longer infer my type. It complains about untouchable variables. This is a case of a "bad failure mode", where a simple error in input can lead to a very complicated error message in output. I thus think that users should knowledgeably opt into GADTs. Maybe if we had a much gentler error message in place here, I could be convinced otherwise. But, for now:</div><div class=""><br class=""></div><div class="">Vote against GADTs!</div><div class=""><br class=""></div><div class="">Richard</div><div class=""><br class=""></div><div class="">PS: A counterpoint is RankNTypes, which I voted for. It would be hard to accidentally write a higher-rank type, and I find the error messages that arise are much clearer. Yes, it's an advanced feature, but one that is appropriately (in my opinion) gated in the code.</div></body></html>