0

I'm unfamiliar with C++, but something that I am trying to build requires the C++ version to be C++ 20 (it uses some features that only cpp 20 has apparently). I believe my current version is lower than that (C++ 17 or something along that line). How can I update my version of C++ to the newest version? I am on Ubuntu 18.04.3 LTS.

3
  • type c++ --version to see your current version number. 17 and 20 make no sense, I'd expect major versions like 8, 9 or 10. Now figure out what version you really need -- which features?
    – ubfan1
    Nov 6 '20 at 7:01
  • Check if the particular feature is supported in GCC, and if so, which version, and upgrade accordingly.
    – muru
    Nov 6 '20 at 7:34
  • 1
    There is "highly experimental" support for the 2020 revision of the ISO C++ standard in g++-10 via the -std=c++2a option. You can install g++-10 on 18.04 from the toolchain-r PPA. Nov 6 '20 at 12:50

Browse other questions tagged or ask your own question.