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 | 6736 reads
|
Browse archives
Active forum topics |
Recent comments
2 hours 43 min ago
22 hours 13 min ago
12 weeks 1 day ago
12 weeks 2 days ago
12 weeks 3 days ago
12 weeks 3 days ago
13 weeks 1 day ago
13 weeks 1 day ago
13 weeks 1 day ago
16 weeks 2 days ago