C++: Difference between revisions

From miki
Jump to navigation Jump to search
(iostream.h or iostream)
 
No edit summary
Line 1: Line 1:
== References ==
* [http://www.acm.uiuc.edu/webmonkeys/book/c_guide/ The C Library Reference Guide]
: Reference for standard C
* [http://www.cplusplus.com/reference/ C++ Reference]
** Also contains description of [http://www.cplusplus.com/reference/clibrary/ C Language Library]
** ... and of [http://www.cplusplus.com/reference/iostream/ IOStream Library]
* [http://www.sgi.com/tech/stl/ Standard Template Library Programmer's Guide from sgi]

== <iostream.h> or <iostream> ==
== <iostream.h> or <iostream> ==
* <code>&lt;iostream&gt;</code> is the standard compliant library. <code>&lt;iostream.h&gt;</code> is deprecated since many many years.
* <code>&lt;iostream&gt;</code> is the standard compliant library. <code>&lt;iostream.h&gt;</code> is deprecated since many many years.

Revision as of 13:00, 13 July 2010

References

Reference for standard C

<iostream.h> or <iostream>

  • <iostream> is the standard compliant library. <iostream.h> is deprecated since many many years.
  • <iostream> contains a set of templatized I/O classes which support both narrow and wide characters (by contrast, <iostream.h> classes are confined to char exclusively).
  • Third, the C++ standard specification of iostream's interface was changed in many subtle aspects. Consequently, the interfaces and implementation of <iostream> differ from <iostream.h>.
  • Finally, <iostream> components are declared in namespace std whereas <iostream.h> components are declared in the global scope.

Note that both libraries cannot be mixed in one program.