Quantcast
Channel: Should I stop using the term C/C++? - Software Engineering Stack Exchange
Viewing all articles
Browse latest Browse all 12

Answer by Paul Draper for Should I stop using the term C/C++?

$
0
0

C/C++ is the intersection of C and C++.

int new; is not C/C++, and neither is vector<int> foo;.

Similarly, C89/C99 is the intersection of these two languages, where neither enum bool { false, true }; or for(int i = 0;;) is allowed.

And C++11/C++14, etc.

It is possible to write code that compiles (and correctly runs) under C++11 and C++14, even though compiling under one doesn't imply it compiles under the other. In fact, a lot people do this.

And a lot of people write code that works in C and C++.

Obviously, the greater the overlap, the more sense it makes; I don't expect to see any questions about C/C++/Java code.


Though it does "make sense" to talk about a common subset of these languages, many questions will not have answers in this subset, e.g. What should main() return in C and C++?

But you can talk about code that works for multiple language specifications, whether those specs are differentiated by "version" or "language name" or otherwise.


Viewing all articles
Browse latest Browse all 12

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>