POV-Ray : Newsgroups : povray.beta-test : Beta 37 and C++0x : Re: Beta 37 and C++0x Server Time
2 Jul 2024 14:20:24 EDT (-0400)
  Re: Beta 37 and C++0x  
From: Warp
Date: 5 Jun 2010 11:14:42
Message: <4c0a69e2@news.povray.org>
Thorsten Froehlich <tho### [at] trfde> wrote:
> The most important question here now is if you tested on any other platform 
> yet. Windows headers tend to pull in lots of C headers, in particular math 
> functions and such, so you may have missed a lot of missing declarations 
> now, unless you added general using declarations everywhere a math function 
> is used...

  One possibility with that is to #include <math.h> instead of <cmath>.
While <math.h> is deprecated in the current standard, it's nevertheless
still standard, and including it should bring only the contents of <math.h>
to the global namespace instead of everything.

  Of course the downside of this is that deprecation means that in the
future it might not work. (I actually haven't checked if C++0x still
defines the .h versions of standard headers as part of the standard in
the same way as C++98 does.)

  While not the cleanest possible solution, at least it's an easy one.

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.