[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Sheflug] c++ & mem



> > Nope, sorry, that's C ;) C++ is...
> >
> > #include <iostream.h>
> >
> > int main()
> > {
> >     cout << "Hi there!\n";
> >     return (0);
> > }
> >
> > . and even that's "C-like" C++ ;)
>
> Actually, as C++ is defined as a superset of C, both of those
> programs _are_ C++. It's just that one of them is also C ;)

Crikey! That means practically everything in Linux is written in C++! And
they say free software developers shun the language.....

Hmmm ;) I don't think that's what most people refer to as "C++" ;)) The
"language" refers to more than just the definition, I would include the ABI,
the STL, and everything else which makes C++ C++. While (most) C will
compile with a C++ compiler, esp. with extern "C" {, I can also do things
like
    #define    BEGIN    {
    #define    END        }

. and start compiling Ada with g++ too. At some point, the definition
becomes stretched ;)

Cheers,

Alex.

---------------------------------------------------------------------
Sheffield Linux User's Group - http://www.sheflug.co.uk
To unsubscribe from this list send mail to
- <sheflug-request [at] vuw.ac.nz> - with the word 
 "unsubscribe" in the body of the message. 

  GNU the choice of a complete generation.