On Tue, Apr 28, 2015, at 08:05 AM, Alex Valavanis wrote:
Summary: We are considering adopting new cleaner & more flexible C++ language features. This may not work with some older compiler versions. Opinions are warmly welcomed!
Hi All,
At the Hackfest, we discussed adopting features from the C++11 standard into our code. The advantages are (among others) significantly cleaner, more flexible and more readable syntax. I've included three examples at the end of this message.
Our discussion included consideration of users of older compilers. A convenient summary of compiler support is available at [1]. Several features (illustrated in the examples below) are well supported, including range-based for loops, type inference and variadic templates.
If we adopt these three specific features, we will require:
GCC >= 4.6 Clang >= 3.1 (or another suitable compiler!)
A complete migration to C++11 would require:
GCC >= 4.8.1 Clang >= 3.3
Yes, so did we get the info on dependencies/versions updated?
One of our main pages: http://wiki.inkscape.org/wiki/index.php/Tracking_Dependencies
That probably also needs to have OS X 10.6 explicitly called out. It currently is limited to gcc 4.2.1. And for all that Macs out there with hardware limitations, updating the OS and/or compiler is not an option.
This happens to include my main laptop :-)
As a secondary factor, we probably need fill in more detail on our wiki page for C++11 http://wiki.inkscape.org/wiki/index.php/C%2B%2B11
I know for a fact that some of the "supported" features on earlier compilers are *not* quite there, and require explicit work-arounds for portable code. There aren't too many of those, but just enough that we will need to track them ourselves and not count on some of the externally referenced pages on C++11 support.