POV-Ray : Newsgroups : povray.programming : C++ version Server Time
10 Dec 2024 19:44:07 EST (-0500)
  C++ version (Message 1 to 2 of 2)  
From: Alessio Sangalli
Subject: C++ version
Date: 17 Dec 2021 13:31:15
Message: <61bcd773$1@news.povray.org>
Hello, what C++ version does the POV-Ray community want to target for 
the future? I see POV_CPP11_SUPPORTED that as far as I were able to 
understand is only used to define POVMS_NULLPTR, but older compilers are 
supported too anyway.

Is there any reason to continue to support compilers older than C++11? 
If we could just assume C++11 (or better, C++17) several sections of the 
code could be rewritten to take advantage of new features of the 
anguage. For example, I'd start with using constexpr instead of #define 
in a lot of cases; kinda of a low hanging fruit, but type checking for 
constants is in my opinion worth having in the 2020's.


Post a reply to this message

From: Chris Cason
Subject: Re: C++ version
Date: 23 Dec 2021 23:37:35
Message: <61c54e8f$1@news.povray.org>
On 18/12/2021 05:31, Alessio Sangalli wrote:
> Hello, what C++ version does the POV-Ray community want to target for 
> the future? I see POV_CPP11_SUPPORTED that as far as I were able to 
> understand is only used to define POVMS_NULLPTR, but older compilers are 
> supported too anyway.
> 
> Is there any reason to continue to support compilers older than C++11? 
> If we could just assume C++11 (or better, C++17) several sections of the 
> code could be rewritten to take advantage of new features of the 
> anguage. For example, I'd start with using constexpr instead of #define 
> in a lot of cases; kinda of a low hanging fruit, but type checking for 
> constants is in my opinion worth having in the 2020's.

This is a question best answered by Christoph Lipka, however I'll add my 
(informal) opinion, and that is with 4.0 we're quite open to changes 
like this. The main constraint (if it is even a constraint) is the 
availability of free, quality compilers that meet the C++11 or C++17 
standards on all the platforms that we target.

-- Chris


Post a reply to this message

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