mirror of
https://github.com/fwbuilder/fwbuilder
synced 2026-05-01 14:47:27 +02:00
refactor: Use C++17 standard
This commit is contained in:
parent
a5b8af05e8
commit
3359246b9a
@ -42,7 +42,7 @@ endif()
|
|||||||
|
|
||||||
### Compiler options
|
### Compiler options
|
||||||
|
|
||||||
set(CMAKE_CXX_STANDARD 11)
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||||
set(CXX_DEFAULT_FLAGS # clang/GCC warnings
|
set(CXX_DEFAULT_FLAGS # clang/GCC warnings
|
||||||
$<$<OR:$<CXX_COMPILER_ID:Clang>,$<CXX_COMPILER_ID:GNU>>:-Wall;-Wextra;-Werror;-Wno-overloaded-virtual>
|
$<$<OR:$<CXX_COMPILER_ID:Clang>,$<CXX_COMPILER_ID:GNU>>:-Wall;-Wextra;-Werror;-Wno-overloaded-virtual>
|
||||||
|
|||||||
@ -299,7 +299,11 @@ protected:
|
|||||||
{
|
{
|
||||||
#ifdef ANTLR_CXX_SUPPORTS_UNCAUGHT_EXCEPTION
|
#ifdef ANTLR_CXX_SUPPORTS_UNCAUGHT_EXCEPTION
|
||||||
// Only give trace if there's no uncaught exception..
|
// Only give trace if there's no uncaught exception..
|
||||||
|
# if __cplusplus >= 201703
|
||||||
|
if(ANTLR_USE_NAMESPACE(std)uncaught_exceptions() == 0)
|
||||||
|
# else
|
||||||
if(!ANTLR_USE_NAMESPACE(std)uncaught_exception())
|
if(!ANTLR_USE_NAMESPACE(std)uncaught_exception())
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
parser->traceOut(text);
|
parser->traceOut(text);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user