Parsa
Parsa

Reputation: 95

'floor': identifier not found

My code was working fine until suddenly I am receiving this message when compiling:

c:\program files (x86)\microsoft visual studio 12.0\vc\include\math.h(700): error C3861: 'floor': identifier not found

I tried to exclude math.h, but I got the same message. when I double click on the message, it takes me to line 700 of file math.h, which uses function floor.

Then, I made an empty project with just one file consisted of only:

#include <iostream>
int main()
{
}

And I am still getting that error. Have I accidentally deleted something? How can I understand what it is?

Upvotes: 0

Views: 3780

Answers (1)

VolAnd
VolAnd

Reputation: 6407

This is quite strange behavior for MSVS.

1) Try to create empty project (without precompiled headers)

2) Try changing

#include <math.h>

to

#include <cmath>

If this not help as well as creation of new empty project, the only way is to ensure that no viruses at your PC and re-install Visual Studio

Upvotes: 3

Related Questions