similar to iostream.h ,conio.h , …
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The standard library is generally all templates. You can just open up the desired header and see how it’s implemented†. Note it’s not
<iostream.h>, it’s<iostream>; the C++ standard library does not have.hextensions. C libraries like<string.h>can be included as<cstring>(though that generally just includesstring.h)That said, the run-time library (stuff like the C library, not-template-stuff) is compiled. You can search around your compiler install directory to find the source-code to the run-time library.
Why? If just to look, there you go. But it’s a terrible way to try to learn, as the code may have non-standard extensions specific to the compiler, and most implementations are just generally ugly to read.
If you have a specific question about the inner-workings of a function, feel free to start a new question and ask how it works.
† I should mention that you may, on the off chance, have a compiler that supports
export. This would mean it’s entirely possible they have templated code also compiled; this is highly unlikely though. Just should be mentioned for completeness.