Is c++ std_lib_facilities.h still used?
Solution 1
In the Appendices (C.3.2 to be specific) of the Book - Programming: Principles and Practice Using C++ -, you can actually find the author explaining about this specific header file - std_lib_facilities.h, and he left a link for the readers to download (http://www.stroustrup.com/Programming/std_lib_facilities.h).
Since learners must download the file and place it in a directory of your choice, I deduce from this point that the file is not a header file people would actually use, but solely for pedagogical uses.
Solution 2
From the Website of Bjarne Stroustrup (Homepage)
Actually the original URL of the std_lib_facilities.h was:
https://www.stroustrup.com/Programming/PPP2code/std_lib_facilities.h
But it gives 404 Not Found Error, as of the time this post was written.
However, if we remove the "Programming" word from the path of the URL to make it:
https://www.stroustrup.com/PPP2code/std_lib_facilities.h
We get the code of the library from the official site.
Hope in future Mr. Stroustrup will rectify the issue.
Related videos on Youtube
r0gue
BY DAY :- works as Tester BY NIGHT :- learning technologies and everything.
Updated on October 31, 2022Comments
-
r0gue over 1 year
I'm learning C++ from Programming : Principles And Practice By Bjarne Stroustrup. They have given a sample program:
// read and write a first name #include "std_lib_facilities.h" int main() { cout << "Please enter your first name (followed by 'enter'):\n"; string first_name; // first_name is a variable of type string cin >> first_name; // read characters into first_name cout << "Hello, " << first_name << "!\n"; }
When I type the same code in visual studio, it gives error for the header file "std_lib_facilities.h". I'm confused with this header file.
Is it still used? What else can I use instead of this header?
-
Cody Gray over 6 yearsThis was never commonly used. It was made up specifically for that book (or, more accurately, the course that accompanied it).
-
MSalters over 6 years@ArtemyVysotsky:
<string>
is one of the headers indirectly included by this"std_lib_facilities.h"
-
Jon almost 5 yearsIf the error is that "std_lib_facilities.h" is using deprecated or antiquated headers. You might want to try the updated version here github.com/BjarneStroustrup/…
-
-
Ernie060 about 4 yearsIt is true that this link is given in the book, but it points to a old version of std_lib_facilitied.h, which might give error messages. The latest version can be found on http://www.stroustrup.com/Programming/PPP2code/std_lib_facilities.h or at the githuspage that user Jon mentioned in the comments under the OP. See also this related question
-
Mark Miller almost 4 years@Ernie060 your link does not seem to work. Your comment is only 1.5 months old. Perhaps something changed recently.
-
Ernie060 almost 4 years@MarkMiller Thanks for pointing this out. I believe the link worked, because I tried it out while reading the principles and practices book. It seems that the whole part www.stroustrup.com/Programming doesn't work anymore... Then one should consult the gibhub page Jon mentioned.