I think that sometimes C++ is odd when you have classes not belonging to the same hierarchy but with some common functions, and for instance you want to make a list of classes that perform a common function. In Java you can use interfases to solve that, in Smalltalk, as it isn't strong type, you have no problem at all, but in C++ you must use some sort of multiple inheritance or a new hierarchy of wrapper classes with the common funcions. I found that the GCC compiler implement a extension called signatures that are like Java interfases and are very usefull in those scenarios. What do you think about signatures or adding something like that to the standard C++??
I think that sometimes C++ is odd when you have classes not belonging to the same hierarchy but with some common functions, and for instance you want to make a list of classes that perform a common function.
In Java you can use interfases to solve that, in Smalltalk, as it isn't strong type, you have no problem at all, but in C++ you must use some sort of multiple inheritance or a new hierarchy of wrapper classes with the common funcions.
I found that the GCC compiler implement a extension called signatures that are like Java interfases and are very usefull in those scenarios. What do you think about signatures
or adding something like that to the standard C++??