[openbeosnetteam] Re: Dial-Up

  • From: "Waldemar Kornewald" <Waldemar.Kornewald@xxxxxx>
  • To: <openbeosnetteam@xxxxxxxxxxxxx>
  • Date: Thu, 10 Apr 2003 11:45:42 +0200

> > - about a Object Oriented (C++) stack design, but as BeOS kernel (and
> > OpenBeOS 's one most probably) linker don't support that well C++, we
> > code
> > our stack in C++ but C only.
>
> If you prefer C++, use C++. We don't have exceptions, but almost
> anything else will work. I would just prefer the module APIs to be C
> only, not to force anybody to use C++ if he doesn't want to.

I would like to use C++ for everything inside the kernel if possible.
The PPP module and the PPPoE module could be C++. :)

I would like that very much.
But, the need of wrappers around C++ modules when writing the protocols
because the modules are in C is not cool.
Maybe we could make C++ the default protocol and add a C++->C wrapper module
that loads the C modules. The core module would load C++ modules and the C++
wrapper module that returns all C modules. This would save some calls and
make C++ modules even easier.
As an alternative we could make a wrapper that can be integrated into the
project as an additional source file and a small macro call with the C++
class as the argument:
WRAP_CPP_NET_MODULE(mycppmod);

Waldemar

Waldemar


Other related posts: