You should probably first decide which C ++ 11 you absolutely want to use, and then find the lowest version of the compiler that supports this on the platforms you want to support. Apache has a good overview of the earliest version of each main compiler (gcc, clang, visual C ++, intel, etc.) ..) that supported the various features of C ++ 11.
In my experience, gcc 4.7 and Clang 3.2 are almost completely complemented (with the exception of things like constructor inheritance, which are useful but not game changers). You can get many useful features with gcc 4.6 (but take version 4.6.3 to avoid many errors) or Clang 3.1, which is nice, since gcc 4.6 is also the official Android NDK compiler (if you want to support it).
If you want to support Linux, you can take a look at DistroWatch , where you can see which gcc versions were installed for each version of the distribution. For example. many popular distributions based on Ubuntu have been running gcc 4.7 for almost a year now and are planning to upgrade to gcc 4.8.1 (full version) in future releases.
On Windows there is Nuwen Distro currently running MinGW 4.8.1 (only 32-bit and no threading). Visual C ++ is not suitable for work and will take some time (a year or more?) To find out where gcc 4.8 and Clang 3.3 are.
Even if distributions do not officially support the latest version, there are repositories of private packages (often supported by the same people who also make official packaging) that provide cutting edge. The LLVM project provides ready-made nightly SVN snapshots that allow you to use many of the features of C ++ 14 (in -std=c++1y ). There are no AFAIK night packages for gcc.
On forcing developers to update compilers / distributions. I donโt think itโs such a big deal (but @ArneMertz's point about first talking to them is very good). Virtual machines are an easy installer (~ 45 minutes from end to end), so if you only want to release only a binary product, then go ahead. For users, this is another matter, so if you provide a header-only template library that all regular users should compile, this should make you much more conservative in your transition pace.
TemplateRex
source share