Welcome, Guest. Please login or register.

Author Topic: Anti C++ sentiment?  (Read 30143 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline EntilZha

  • Full Member
  • ***
  • Join Date: Feb 2002
  • Posts: 131
    • Show all replies
    • http://www.hyperion-entertainment.com
Re: Anti C++ sentiment?
« on: January 26, 2003, 12:53:19 AM »
> That's so strange to read in 2003 that people still don't like C++ and prefer C.

Hey, if you look at the Windows programming community, they prefer VisualBasic over C

Most people still fall for the myth that C++ adds too much overhead.
- Thomas
Avatar by Karlos
 

Offline EntilZha

  • Full Member
  • ***
  • Join Date: Feb 2002
  • Posts: 131
    • Show all replies
    • http://www.hyperion-entertainment.com
Re: Anti C++ sentiment?
« Reply #1 on: January 26, 2003, 01:04:11 AM »
> i love C++!

Me too.

> perhaps also people arent used to thinking OO, procedual is easy, but for some OO is bit daugnting?

The way C++ handles OO (i.e. structures with data and functions in one entity) is really more of a procedural approach than an OO approach.. That's why I think C++ is in fact relatively easy to learn when you know C...

> amigaos includes etc... need to be re-done in a C++ OOP way... that would definently get more support

The problem with C++ in the system is that it can't be done without locking out other languages, i.e. if you have a C++ interface, you can't use it from C without troubles..

Plus, you have the non-standardized way that name mangling and object layout is handled...
- Thomas
Avatar by Karlos
 

Offline EntilZha

  • Full Member
  • ***
  • Join Date: Feb 2002
  • Posts: 131
    • Show all replies
    • http://www.hyperion-entertainment.com
Re: Anti C++ sentiment?
« Reply #2 on: January 26, 2003, 11:26:15 AM »
> i think you may be a bit confused as to what OOP is all about?

No, not really ;)

OO means objects that have data and methods. Methods are sent from object to object and the object manipulates it's data.

However, in C++, you have more of a procedural interface.

In C, you write do_something(object);
In C++, this becomes object->do_something();

That's a lot less OO than for example smalltalk...

> what i acctually mean, is that you could have both c++ & C includes, the C ones would form the basis
> for includes for other programming languages

Include files wouldn't be enough... there would have to be a class framework as well...

About the non-standardized way of name mangling and object layout:
Every compiler is free to implement name mangling in any way it sees fit. There is (or better was) no standard. So if the system is using a C++ framework, the system would have to define the name mangling, and all compilers would have to implement that...

That's the problem BeOS has: They have their system interfaces as C++, so you were forced for some time to use the BeOS compiler... There's a gcc variant in the meantime, though...
- Thomas
Avatar by Karlos