Question

I keep reading that object-oriented programming can basically be done in any programming language, and that in order to do so, explicit language support is not required. I.e. one can write object-oriented programs in, say, plain C.

What good examples of OO design using a procedural language are there, apart from GTK+?

Which open source projects are good examples of procedural design, on the other hand? (preferably C)

Was it helpful?

Solution

In C, OO programming usually takes the form of calling particular initialization and cleanup functions on struct pointers, and for polymorphism, passing around structs of function pointers. One example I can think of offhand is KVM.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top