C++ (as most OO languages I suppose) allows a better representation of the problem, and I find that nice C code usually looks like:
void* handle = blah_create()
int rc = blah_do_something(handle, some data)
IOW, people have tried to write OO code with a non-OO language. The Linux kernel is full of this kind of things, not even mentioning structures containing function pointers.
So if what people want is to write OO code, I find it easier to do it with a OO language!
Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds