A minor change appears to have enabled explicit qualification for typeclasses. For example, this now works:
//////////////////////////////////////////////// typeclass X[t] { virtual fun f:t->t; } instance X[int] { fun f: int -> int = "$1*2"; } var y = X[int]::f 1; println y; /////////////////////////////////////////////// Typeclasses and modules are now creeping closer together. Module type parameters delegate to members, that is, the universal quantification goes to the members. For typeclasses it doesn't, the parameter is monomorphised (is this an existential type?). However the module case is just syntactic sugar, so we can view typeclasses as an *extension* of modules by adding a type parameter and virtual functions (plus, the notion of instantances to fill in the virtuals). -- John Skaller <skaller at users dot sf dot net> Felix, successor to C++: http://felix.sf.net ------------------------------------------------------------------------- SF.Net email is sponsored by: The Future of Linux Business White Paper from Novell. From the desktop to the data center, Linux is going mainstream. Let it simplify your IT future. http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4 _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language