Question

I just noticed that the templates dictated by the c++11 Standard [26.8 c.math] for the <cmath> header are missing from the version of the c++ standard library shipped with visual studio 2010.

In particular I was looking for std::signbit but a search on msdn confirmed what I was seeing in the shipped header (namely, a series of using directives which import only the "old" C names). I didn't recall reading about this deviation from the Standard, nor is it explicitly pointed out in the msdn documentation.

What is the best workaround to get the missing functionality?

Is there some official communication about fixing this in some future release of Visual Studio?

EDIT The version of the Standard which I was referring to is outdated, so my claim of incompleteness is ill-aimed. signbit is still missing, but it's not a template, it's an overloaded function. Thanks to @Xeo for the clarification.

Was it helpful?

Solution

First, these aren't templates (would be strange, as there are no templates in C and <cmath> is a C header).

Then, VS2010 was shipped way before C++11 was finished, so it's understandable that not all of the stdlib is included there.

FWIW, VS11 claims to have the whole C++11 stdlib covered.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top