[clean-list] where are function type restrictions discussed?

terrence.brannon terrence.x.brannon at jpmchase.com
Tue Aug 26 16:05:07 MEST 2008




terrence.brannon wrote:
> 
> 
> 
> I am confused by the pipe syntax. Where is it fully discussed with
> examples?
> 
> 

Here's another example:

    sumlength :: [t] t t -> (t,t) | +, one t

I'm guessing this is saying that both + and one must be applicable to the
argument of type t

So in some cases it seems to be saying that a certain function must be
applicable and in other cases it is saying that the datum has to be of a
certain type.

But I dont know where to find this fully described with examples, so I'm
sort of hitting in the dark :)



-- 
View this message in context: http://www.nabble.com/where-are-function-type-restrictions-discussed--tp19162663p19162757.html
Sent from the Clean mailing list archive at Nabble.com.



More information about the clean-list mailing list