I am looking for a solution to the same problem in the question What is the best way to read an entire file into a std::string in C++? and looking at the dates being way back in the mists of 2008.
Is there a better C++11/C++17 solution for this problem?
That is with 'better' being defined in any way you'd care. More space/time efficient, more readable, a shorter one-liner. Justifying why your solution is better would be appreciated
(C++11 is preferred for my problem, but I don't want to have the same issue as the previous question too soon, C++17 is welcomed happily.)