0

It's been several days since my MS Visual (2013 : 12.0.311001.00 update 4) became kind of nut and behave strangely:

Here are the symptoms

  1. I have a simple hello word project that builds fine.
  2. I insert one mistake into the code (see below).
  3. I build project.
  4. Visual (I'd rather say the compiler) is perfectly find with the new error inserted. It doesn't rebuild nothing and run the previous version of the code.
  5. The mistake is however highlighted in red in Visual editing panel.

here is the code (which is not the guilty here)

include <iostream>

int _tmain(int argc, _TCHAR* argv[])
{
    char c;
    std::cout << "Please help!!!" << std::endl;
    std::cin >> c;
    mistake

    return 0;
}

mistake above is not detected as a code change

What I've tried:

  • Uninstall reinstall Visual => same behaviour
  • Uninstall and reinstal other version of Visual => same behaviour
  • Tried with a very simple project to make sure that my real project and cmake chain is not responsible for this. This new very simple project is the main above

What other information I can provide :

  • Already tried the stuffs in Tools>Options> project and solutions > build and run where i set "on run when project are out of date" = "always build". => no change
  • If i update a header file referenced in my main file, the build process will go just fine. Of course I don't want to have to rememeber all the header files i need to modify to rebuild my project correctly. This no accetable solution.
  • I have installed no other tool/component that could explain this.
  • There were no visual or windows update at the same time that could be responsible for this.
  • This happens also on one of my colleague's a computer (but not all of them). I can see no common radix between him an I that could help the investigation
  • This happened next to a time shift in my country. Not sure the translation to english is ok but to be precise enough : time reference has been advanced from one hour.

Any help would be very appreciated because I've already spent several days investigating on this and rebuilding all my projects takes so many time it starts to make me crazy.

Oliver
  • 43,366
  • 8
  • 94
  • 151
traiangueul
  • 71
  • 1
  • 1
  • 5
  • Although the option "save-on-build" seems to be unuvailable in my version of visual, I can tell the file was saved. So, yes. – traiangueul Apr 07 '15 at 09:05
  • Checked again: the file is automatically saved when building. – traiangueul Apr 07 '15 at 09:07
  • Is there someway to clean all data that visual may cache? I've tried renaming AppData\Roaming\Microsoft\VisualStudio\12.0 and AppData\Local\Microsoft\VisualStudio\12.0 but that did not solve my problem. Is there any other location i should rename/remove? maybe in AppData\Local\Temp ? – traiangueul Apr 07 '15 at 15:55
  • Also tried to clean registry with ccleaner. Same results – traiangueul Apr 07 '15 at 16:21
  • today i tried to uninstall visual, then clean registry base, removed several (what i assumed to be) visual studio temporary folders, restart computer, clean again temporary folders and reinstall visual studio. Then i created a new simple project from scratch. And guess what. Problem still there. So desperate me :-( – traiangueul Apr 08 '15 at 09:09
  • ok. New tip: a colleague of mine just set a new computer up. She installeld MS visual studio 2013 update 4, wrote a simple main and faced the same problem. Note that she previously had the problem on her former computer. But we thought that on a new computer visual would work fine. Nope. Could this be linked with her (our) microsoft account? something coming from the network? – traiangueul Apr 17 '15 at 08:52
  • ok new breaking breakthough today!!!! This is not a solution though. I notitced that if I wait one hour and then perform an update in my cpp file, hitting F5 will make everything build again (as exepected in nominal case). Juste one time unfortunately (then I must wait one extra hour and so on). So i went to by project folder and noticed that my projectName.lastbuildstate file is dated one hour in the future. My new questions now are "how is that possible? Who generates this file? Can i modify the behaviour of the thing that generates this file? " – traiangueul Apr 27 '15 at 14:44

1 Answers1

0

Ok, so I don't know neither what happened nore what is responsible for this problem but I have a workaround/Fix (not sure this is a fix because I can't locate the problem precisely) to propose.

I told this happened next to a time shift in my country and my recent discovery confirmed that.

What I did to fix my problem is the following :

Switched my time zone from local one to UTC, validate, and then switched it back to my local time zone again, validate again. And then, it worked.

Strangest thing I have ever faced. Definitely classified in my "WTF problems" section.

Really hope someday this will help someone.

traiangueul
  • 71
  • 1
  • 1
  • 5