<p>Hi,</p>
<p>I am working on a project which has some similarities with DBUS, since it's an IPC framework involving a daemon process which dispatches messages to clients connected to it over a UNIX domain socket.<br>
It's currently completely written in C. Since the daemon has to support some pluggable components, I use some C structures which mainly contain function pointers pointing the my plugins specific function.<br>
These structures can be seen as a virtual function tables as they are know in the C++.<br>
Since implementing this in C is actually quite painful and error prone, I wondered whether it would make sense to implement this in C++ instead of C, WITHOUT using STL.</p>
<p>According to me, there are already a lot of benefits of using the C++ language itself over C :<br>
- Helps making the design of your application cleaner, when using object oriented concepts<br>
- Provides stricter type checking<br>
- Allows using templates</p>
<p>Now the drawbacks (?):<br>
- Need a C++ compiler (nowadays, there's one on every platform we support, right ?)<br>
- Need to link against libstdc++ library (this can be avoided, as it is described in this thread : <a href="http://stackoverflow.com/questions/1653047/avoid-linking-to-libstdc">http://stackoverflow.com/questions/1653047/avoid-linking-to-libstdc</a>)</p>
<p>So now my question : Would it make sense (or would it have made sense) to implement DBUS in C++, without using any of the C++ libraries (STL, libstdc++, etc...), since the language itself provides some benefits over C, without any drawback (apart from the fact that some people don't know C++) ?</p>
<p>What do you think? </p>
<p>Best regards<br>
Jacques</p>