Should I stop using the term C/C++? -


i understand c , c++ different languages when learning c++ told c subset of c++ or c++ c classes. , quiet true until appearance of c++x0, c++11 (or modern c++ 11/14/17 in general). in fact (specially when working on embedded systems) it's find code written in c++ lot of parts written entirely in pure c language. here have several questions:

  1. should stop using term c/c++?
  2. if answer #1 yes, how call program use mix of c , c++?
  3. given both of them 'different' languages @ point c++ compilers stop supporting code written in c language (since modern c++ diverging c mentality basic stuff pointers, dynamic memory handling, etc)
  4. is there right collaboration between people makes standards of c/c++ keep compatibility
  5. if #4 yes, such collaboration end in near future appearance of modern c++ (11/14/17)

i know there similar questions, i'm sure lot of people share these doubts i'm interested answers specially points have c++ tendency in near future.

i told c subset of c++ or c++ c classes. , quiet true until appearance of c++x0, c++11 (or modern c++ 11/14/17 in general).

c has never been subset of c++. example c89 not subset of c++98.

a few examples:

  • the c89 identifier-list form function parameter declaration not supported in c++
  • c89 , c++98 have different types characters constants
  • c89 , c++98 have different types string literals
  • logical operators yield different types in c89 , c++98 (int vs bool)
  1. should stop using term c/c++?

yes.

  1. if answer #1 yes, how call program use mix of c , c++?

a program either c or c++ (if basic program can compiled either c or c++ compiler). compiler using compile it? should answer question. harbison & steele coined term clean c designate common subset of c , c++ think bad idea.

edit: admit technically can link c , c++ objects files in single program oth there many languages allowed mixed in single program example java , c++. think using term c/c++ program adds confusion written in single language called c/c++.

  1. given both of them 'different' languages @ point c++ compilers stop supporting code written in c language (since modern c++ diverging c mentality basic stuff pointers, dynamic memory handling, etc)

there many features (example: variable length array, flexible array member, _generic, ...) of c99 or c11 not supported c++ version.


Comments

Popular posts from this blog

1111. appearing after print sequence - php -

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

Ruby on Rails, ActiveRecord, Postgres, UTF-8 and ASCII-8BIT encodings -