[Grace-core] On Gradual Typing

Kim Bruce kim at cs.pomona.edu
Thu Jul 25 15:00:26 PDT 2013


That is my understanding as well.

Kim



On Jul 24, 2013, at 7:13 PM, Timothy Jones <Timothy.Jones at ecs.vuw.ac.nz> wrote:

> On 25/07, Michael Homer wrote:
>> He apparently also has an answer to the question I had about blocks,
>> but I don't remember what it is. I think the general sense is that
>> extra arguments to blocks shouldn't be permitted. The static typing
>> I'm not sure about, but it is clear enough in the usual cases.
> 
> I believe the agreement was that blocks accept exactly the same number of
> arguments as parameters they define, but there's nothing stopping you writing
> something like this (ignoring block generics):
> 
>> method maybeApply5(bl : Block0 | Block1) {
>>    match(bl)
>>        case { Block0 -> bl.apply }
>>        case { Block1 -> bl.apply(5) }
>> }
> 
> -- 
> Tim
> _______________________________________________
> Grace-core mailing list
> Grace-core at cecs.pdx.edu
> https://mailhost.cecs.pdx.edu/mailman/listinfo/grace-core




More information about the Grace-core mailing list