News for hackers. Stuff that matters.
Re:The End of the General Purpose Operating System by sqeaky on Saturday November 05, 2016 @08:51PM (#12882813)
I covered exactly this. I write code for windows/Linux/Mac OS X. Write a class to contain those ifdef. I did this before C++11 as well.

This isn't a new technique, but for some reason people adopting C++11 and C++14 seem more willing to do it than people who wish C++ was really just C with classes.

Also, write unit tests to test the class. Run the Tests in CI on every platform and a variety of configs. It is not hard and there great free or cheap tools Like Jenkins, TravisCI and Appveyor.

Re:The End of the General Purpose Operating System by pjmlp on Sunday November 06, 2016 @03:11AM (#12884114)
> This isn't a new technique, but for some reason people adopting C++11 and C++14 seem more willing to do it than people who wish C++ was really just C with classes.

This was exactly part of the problem.

Most of the enterprise code I used to deal with was not even that, rather compiling C with C++ compiler.

However my point with rich runtimes was that you shouldn't bother to even do that, the runtime is the OS, kind of.