-
Notifications
You must be signed in to change notification settings - Fork 273
CBMC C++ frontend doesn't detect implicit -std
option
#2359
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Suggestion: I think this series of problems with modern compilers indicates it's time we were CI'ing against multiple gcc versions. |
At least for |
(But I'm accepting responsibility for eventually doing so.) |
Gah, awkwardly the GCC default is actually |
Is this obsoleted by #2364? |
That will fix it, if it works as I hope, yes. |
Maybe the errors I'm seeing fit in this issue report (resp. an update of the used branch I've just used the latest version of branch
Using
doesn't change that. Without
My system is Linux 64 bit with gcc 7.3. |
This was fixed in #2364 (and further extended in #6402). The issues noticed by @sschwarzmann, however, remain (and are documented in various issues filed against this project): our C++ front-end requires work to fully support C++11 and later. |
With
g++-7
at least,-std=c++14
is implied if the user doesn't make an explicit choice. However, cbmc's frontend expectsc++03
unless something is explicitly specified. It should either check the__cplusplus
defined by the compiler to find out what it understood to be the prevailing standard and act accordingly, or force-std=c++03
. The former is better, as a configure script would be reasonable to avoid using-std
if the compiler appears to be modern enough that it supports the desired language version without an explicit switch.This causes all
cpp
regression tests that usedecltype
and similar to fail when the real compiler is g++7.The text was updated successfully, but these errors were encountered: