The 1989 C standard is known officially as ANSI/ISO 9899-1989, Programming Languages – C, and this document refers to the 1989 C standard as C89. The 1990 ISO revision of the standard is known officially as ISO/IEC 9899-1990, Programming Languages – C, which is referred to in this document as “C90″. The next version of [...]
Continue Reading..Archive for the ‘Comparisions’ Category
Differences between C and C++ Continued…
The usage of standard C functions
Normal C functions, e.g., which are compiled and collected in a run-time library, can also be used in C++ programs. Such functions however must be declared as C functions. As an example, the following code fragment declares a function xmalloc() which is a C function:
extern "C" void *xmalloc(unsigned [...]
Compiling a C program by a C++ compiler
For the sake of completeness, it must be mentioned here that C++ is `almost’ a superset of C. There are
some small differences which you might encounter when you just rename a file to an extension .cc and
run it through a C++ compiler:
->In C, sizeof(’c’) equals sizeof(int), ‘c’ being any ASCII character. The underlying philosophy is
probably [...]
Continue Reading..