C ++ - release of precompiled headers
Ok, so I'm writing something in C ++ and everything was fine last night, I could compile without issue. I saved all my stuff and closed VS 2010 Ultimate. This morning when I went to work on my stuff, I tried recompiling and I had just over 200 errors, I couldn't figure out why so I noticed that there were a few warnings than usual and it says it was missing my headers ...
Warning C4627: '#include <iostream>': skipped when looking for precompiled header use.
I tried to disable precompiled headers for my main .cpp, but when I compile it it just gives me even more errors. Is there a way to fix this?
source to share
You haven't posted more information yet, although the warning says it missed #include<iostream>
it because the preprocessor was expecting a pre-compiled header file. In case your Visual C ++ project is usually stdafx.h file, try adding it like,
#include "stdafx.h"
Add #include "stadfax.h" at the top of your cpp file, just above the other included directives.
source to share