devxlogo

How standard is the string class ?

How standard is the string class ?

Question:
We may want to use the C++ string class if itis specified as part of some open standard andis not just provided by the g++ compiler. Is the string class part of some standard, and can I except to see it with other compilers? Is it portable ?

Answer:
I’m afraid I haven’t worked with the g++ compiler, and the answer is entirely dependent on exactly what you mean by “the C++ string class.”The STL, or standard template library, includes a string class that is pretty much standard. Other classes, such as Microsoft Foundation Classes’ CString class, are not.

devx-admin

Share the Post: