User loginNavigation |
Random "if it bends it is funny, if it breaks it isn't funny" line of thoughtI was wondering how something like duck typing might work in C# or Java (there are other strict languages which do support duck typing, O'Caml for instance). Seems like you would have to have lots of interfaces and then list them when implementing them. Basically every public method would have an interface describing it, and then each class would laboriously list all those interfaces. Actually it all falls apart because I don't think one can say a method takes a set of interfaces for a single parameter. You would have to automatically generate the combinatorical set of interface mixins, and use those in the method signitures. (Just musing over the range of things one could - not particularly want to - do with the way Java/C# are already defined.) By raould at 2006-11-10 23:15 | LtU Forum | previous forum topic | next forum topic | other blogs | 6423 reads
|
Browse archives
Active forum topics |
Recent comments
22 weeks 6 days ago
22 weeks 6 days ago
22 weeks 6 days ago
45 weeks 19 hours ago
49 weeks 2 days ago
50 weeks 6 days ago
50 weeks 6 days ago
1 year 1 week ago
1 year 6 weeks ago
1 year 6 weeks ago