<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></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 8, 2020, at 4:32 AM, Joachim Breitner <<a href="mailto:mail@joachim-breitner.de" class="">mail@joachim-breitner.de</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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; float: none; display: inline !important;" class="">Would you argue that it should not be included even _if_ we’d include</span><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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=""><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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; float: none; display: inline !important;" class="">GADTs and/or TypeFamilies? Or are you saying that MonoLocalBinds</span><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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=""><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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; float: none; display: inline !important;" class="">shouldn’t be in; GADTS/TypeFamilies are bad without MonoLocalBinds, and</span><br style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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=""><span style="caret-color: rgb(0, 0, 0); font-family: Menlo-Regular; font-size: 11px; 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; float: none; display: inline !important;" class="">thus GADTs/TypeFamilies ought to be left out?</span></div></blockquote></div><br class=""><div class="">No. If we have GADTs and/or TypeFamilies, then we should absolutely have MonoLocalBinds -- GADTs and TypeFamilies are wonky without MonoLocalBinds. I'd prefer not to have any of them on by default.</div><div class=""><br class=""></div><div class=""><div class=""></div><blockquote type="cite" class=""><div class="">On Dec 8, 2020, at 10:36 AM, Eric Seidel <<a href="mailto:eric@seidel.io" class="">eric@seidel.io</a>> wrote:</div></blockquote><br class=""><div class=""><blockquote type="cite" class="">Aha, so what you're saying is that with NamedWildCards but not PartialTypeSignatures, GHC will tell you what `_a` was solved for, but it won't accept the resulting program? I didn't realize that NamedWildCards did anything in the absence of PartialTypeSignatures, but I agree that this is better. I was already voting for NamedWildCards, but now I'm inclined to additionally vote against PartialTypeSignatures.</blockquote><br class=""></div></div><div class="">Exactly, yes. I am strongly against PartialTypeSignatures as an extension, as users should have to opt into accepting partially-written programs.</div><div class=""><br class=""></div><div class=""></div><blockquote type="cite" class=""><div class=""><br class=""></div><div class=""><div class="">On Dec 8, 2020, at 11:59 AM, Iavor Diatchki <<a href="mailto:iavor.diatchki@gmail.com" class="">iavor.diatchki@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><span class="" style="float: none; display: inline !important;">It seems odd to turn on an extension [NamedWildCards] that doesn't do anything, and it is entirely there to make *another* extension work better?   Wouldn't it be better to make `PartialTypeSignatures` imply `NamedWildCards`?</span></div></div></blockquote><div class=""><span class="" style="float: none; display: inline !important;"><br class=""></span></div><div class=""><span class="" style="float: none; display: inline !important;">NamedWildCards *does* do something on its own -- it just doesn't accept new programs.</span></div><div class=""><span class="" style="float: none; display: inline !important;"><br class=""></span></div><div class=""><span class="" style="float: none; display: inline !important;">If we consider</span></div><div class=""><span class="" style="float: none; display: inline !important;"><br class=""></span></div><div class=""><span class="" style="float: none; display: inline !important;"><div class=""></div><blockquote type="cite" class=""><div class="">foo :: _a -> _a</div><div class="">foo True = False</div><div class="">foo False = True</div></blockquote><div class=""><br class=""></div><div class="">Without NamedWildCards, we get</div><div class=""><br class=""></div><div class=""><div class=""></div></div><blockquote type="cite" class=""><div class=""><div class="">Bug.hs:4:5: error:</div><div class="">    • Couldn't match expected type ‘_a’ with actual type ‘Bool’</div><div class="">      ‘_a’ is a rigid type variable bound by</div><div class="">        the type signature for:</div><div class="">          foo :: forall _a. _a -> _a</div><div class="">        at Bug.hs:3:1-15</div><div class="">    • In the pattern: True</div><div class="">      In an equation for ‘foo’: foo True = False</div><div class="">    • Relevant bindings include foo :: _a -> _a (bound at Bug.hs:4:1)</div></div></blockquote><div class=""><br class=""></div><div class="">With NamedWildCards, we get</div><div class=""><br class=""></div><div class=""><div class=""></div><blockquote type="cite" class=""><div class="">Bug.hs:5:8: error:</div><div class="">    • Found type wildcard ‘_a’ standing for ‘Bool’</div><div class="">      To use the inferred type, enable PartialTypeSignatures</div><div class="">    • In the type signature: foo :: _a -> _a</div></blockquote><br class=""></div><div class="">I think that prefixing a variable name with an underscore is a convenient, lightweight way of asking GHC to tell me what a type should be.</div><div class=""><br class=""></div><div class="">Richard</div></span></div></body></html>