Re: Proposals and owners

2009-07-29 Thread Stephanie Weirich

Ok, I've put together a page on EmptyDataDecls:

http://hackage.haskell.org/trac/haskell-prime/wiki/EmptyDataDecls

Cheers,
Stephanie
___
Haskell-prime mailing list
Haskell-prime@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-prime


Re: help from the community?

2007-02-01 Thread Stephanie Weirich

Here are some of my comments to Iavor's proposals:
 Notation for Schemes

 PROPOSAL: be liberal:

 allow empty quantifier lists

 allow variables that are not mentioned in the body of a type (but  
warn)


 allow predicates that do not mention quantified variables (but warn?)

For the reasons that others have expressed, I prefer that we not be  
liberal here. I think we should reject the first two cases. I'm  
ambivalent about the last one.


I don't think we want to allow types like:

forall . Int   or forall a b. Int

These types are mostly bugs. Furthermore, rejecting them doesn't  
limit expressiveness: they should both be equivalent to Int, so  
user could just write Int. I can't really think how allowing these  
types extends the expressiveness of the language, nor can I imagine a  
situation where someone would prefer seeing one of these types  
instead of Int. And in fact, given restrictions on higher-rank and  
impredicativity, Int would be a much better type to use. (This issue  
is *slightly* related to the one below. Perhaps different answers for  
that question may interact with this one.)


On the other hand, perhaps there is uses for types like  C a = a -  
a  where a is bound in some external context? The last issue doesn't  
seem very straightforward to me.




 Equivalence for type schemes

 PROPOSAL: Use syntactic equivalence modulo

 alpha renaming

 order/repetition of predicates (i.e. compare predicates as sets)

This proposal doesn't go as far as entailment---which would equate  
the types forall . Int and Int.


And also types that are not alpha-equivalent but differ only in the  
order of quantification:


i.e.

forall a b. (a,b) - a

=/=

forall b a. (a,b) - a

are *not* alpha equivalent, but it would be nice if they were  
semantically equivalent.


I guess at this point we need to hear from implementors about how  
difficult it would be to implement semantic entailment? Is there  
another point in the space between syntactic equivalence and full  
entailment?  (i.e. normalize types in some way and then compare them?)




 Higher-rank types and data constructors

I'll chime in and say that I'm in favor of rank-n over rank-2 types,  
and I would like to allow subexpressions to have higher-rank types as  
well. As a user (not an implementer) I find this to be the easiest to  
think about, as I only have to worry about the difference between  
monotypes and polytypes where type inference is concerned. If my  
program doesn't typecheck, I need only add more annotations. I don't  
need to rewrite the code.


About this example:

 data T  = C1 Int (forall a. (Eq a, Show a) = a - a)
| C2 (forall a. (Show a, Eq a) = a - a)
 h  :: a - a - Int
 h _ _   = 1
 test= h (C1 1) C2
Note that even if partial applications (of constructors and other  
higher-rank functions) are allowed, in this example would still be  
rejected because it requires impredicative polymorphism. However,


-- type abbreviation for convenience

type U = forall a. (Eq a, Show a) = a - a

h :: U - U - Int

h _ _ = 1
test  = h (C1 1) C2

should be accepted if we chose the proposal for type scheme  
equivalence above.


---Stephanie

On Jan 25, 2007, at 5:39 PM, isaac jones wrote:


On Sun, 2007-01-21 at 14:25 -0800, Iavor Diatchki wrote:

Hello,

I have written some notes about changes to Haskell 98 that are
required to add the polymorphic components extension.   The purpose
of the notes is to enumerate all the details that need to be  
specified

in the Haskell report.  I don't have access to the haskell-prime wiki
so I attached the notes to the ticke for polymorphic components:
http://hackage.haskell.org/trac/haskell-prime/ticket/57

When there are different ways to do things I have tried to enumerate
the alternatives and the PROPOSAL paragraph marks the choice that I
favor.


Does anyone have any feedback on this work?  The critical path for
Haskell', at this point, is writing these bits of the report and  
having

them validated by the community.

But no one has read and commented on these topics:
- Plans for changes to the report relating to Polymorphic Components
- Draft changes to the report for pattern guards

I understand that taking the time to pour over the report is a bit  
hard,

but we desperately need people who are willing to do so if we're going
to make progress.

I think Iavor and I will start to make these changes tomorrow; does
anyone have feedback before then?

peace,

  isaac


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


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


Re: Class System current status

2006-05-12 Thread Stephanie Weirich

Simon Peyton-Jones wrote:

My suggestion is this:

* Specify MPTCs in the main language

* Specify FDs in an Appendix (with some reasonably conservative
	interpretation of FDs). 


* A Haskell' implementation should implement the Appendix, and
programmers can write programs against it.  But
we are advertising specifically that we aren't sure, one way
or the other, whether FDs will stay in the language for ever

  

Simon,

Why is an Appendix is better than just a footnote in the Standard that 
says we aren't sure, one way or the other, whether FDs will stay in the 
language for ever.  Why do we need this extra structure?


I'm worried that this extra structure could be confusing. In particular, 
if someone says this program is pure Haskell'  what will that mean? In 
practice, will it be clear whether pure Haskell' includes the Appendix? 


--Stephanie

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


Re: Class System current status

2006-05-11 Thread Stephanie Weirich
So it looks like we're stuck at pretty much the same proposals for the 
class system.


a) standardize on MPTC and FDs using rules from CHR paper.
b) don't standardize anything, and wait for ATs to take over
c) punt---standardize the library and exact form of FD for that library, 
but no more, or map out some longer timeline for this issue.


For a while I thought (a) was the clear choice. The theory has been 
worked out, we have a lot of experience using them, and key libraries 
depend on them.  However, not everyone is convinced by (a) because of  
the fear of too early standardization. We may end up with a lot of code 
that uses a feature that will eventually be deprecated.  There are 
perhaps three counterarguments to this point of view:
 - We're already in that state. There *is* a lot of Haskell code that 
uses FDs, it's just not Haskell 98 code. Whenever ATs take over, we'll 
still have to deal with this code.
 - It may be that all uses of MPTCs/FDs may be subsumed by ATs, and in 
fact there is (or will be) some automatic way of translating FD code to 
AT code.
 - It may not be all bad for a future Haskell standard to include both 
ATs and FDs. Certainly more complicated, but I haven't seen any evidence 
that these features interfere with eachother.


Are there any merits to these counterarguments?

More generally, our discussion about the class system seems to be 
stalled. How should we to come to a decision?


--- Stephanie
___
Haskell-prime mailing list
Haskell-prime@haskell.org
http://www.haskell.org//mailman/listinfo/haskell-prime


Class System status

2006-04-17 Thread Stephanie Weirich
I've been working on a summary page for the class system proposals 
(http://haskell.galois.com/cgi-bin/haskell-prime/trac.cgi/wiki/ClassSystem), 
similar in spirit to the Concurrency page that Simon Marlow has been 
developing.  This page is important because it lists all of the 
proposals not related to MPTCs as well as trying to capture the big 
picture about where we stand with respect to MPTCs. I've been trying to 
not duplicate text that appears elsewhere in the wiki, but just provide 
a consistent picture of the state of the discussions on the mailing list.  

Please take a look at this page and help me fill it out. In particular, 
I've been trying to take a pulse of where we stand on some of 
these issues, and some of you may not agree! Tell me if I'm off the 
wall. Also, I've (mostly) concentrated on issues that have tickets, so I 
may have missed some issues that were only discussed in the mailing list.

Please let me know if there is anything I've forgotten.

Thanks,
Stephanie

___
Haskell-prime mailing list
Haskell-prime@haskell.org
http://haskell.org/mailman/listinfo/haskell-prime