-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Latest version of format package does not compile with C++98 #12
Comments
Sorry, I can't reproduce it here. What compiler do you use? |
GCC 4.2.2 |
This iss because the new version is not backward compatible anymore with C++98 instead I had to add g++ -std=c++11 without out GCC4.8.1 fails with /tmp/format.h:919:5: error: identifier 'noexcept' is a keyword in C++11 [-Werror=c++0x-compat] define FMT_NOEXCEPT(expr) noexcept(expr)
/tmp/format.h:919:25: error: expected ',' or '...' before 'false' define FMT_NOEXCEPT(expr) noexcept(expr)
/tmp/format.h:54:42: error: ISO C++ forbids declaration of 'noexcept' with no type [-fpermissive] define FMT_NOEXCEPT(expr) noexcept(expr) |
Unfortunately our project is still on 4.2.2 and next year it will move up, so for now I'm stuck unless it's possible to maintain compatibility with old GCC versions. |
/format.h: In function 'fmt::Formatter<fmt::NoAction, char> fmt::Format(fmt::StringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::NoAction, Char = char]' is private
/format.h:1226: error: within this context
/format.h: In function 'fmt::Formatter<fmt::NoAction, wchar_t> fmt::Format(fmt::WStringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::NoAction, Char = wchar_t]' is private
/format.h:1230: error: within this context
/format.h: In function 'fmt::Formatter<fmt::Write, char> fmt::Print(fmt::StringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::Write, Char = char]' is private
/format.h:1246: error: within this context
In file included from /format.cc:34:
/format.h: In function 'fmt::Formatter<fmt::NoAction, char> fmt::Format(fmt::StringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::NoAction, Char = char]' is private
/format.h:1226: error: within this context
/format.h: In function 'fmt::Formatter<fmt::NoAction, wchar_t> fmt::Format(fmt::WStringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::NoAction, Char = wchar_t]' is private
/format.h:1230: error: within this context
/format.h: In function 'fmt::Formatter<fmt::Write, char> fmt::Print(fmt::StringRef)':
/format.h:1112: error: 'fmt::Formatter<Action, Char>::Formatter(const fmt::Formatter<Action, Char>&) [with Action = fmt::Write, Char = char]' is private
/format.h:1246: error: within this context
The text was updated successfully, but these errors were encountered: