All pastes #265799 Raw Edit

Untitled

public text v1 · immutable
·published 2006-12-03 17:34 UTC
rendered paste body

fun comp' comp = fn (a,b) => if comp(a,b)=GREATER then a else b;



fun largest(comp,l) = foldl (comp'(comp)) hd(l) l;

(* Den klagar på listan l och säger:

! Type clash: expression of type
!   ('a list -> 'a) list
! cannot have type
!   'a list
! because of circularity

Kan någon förklara varför?

*)