From 54320c0d8e8f0ba64d801740031d09443830bc0e Mon Sep 17 00:00:00 2001 From: Fabian Posch Date: Fri, 9 Aug 2024 18:17:46 +0200 Subject: [PATCH] fix dynamic exception deprication for newer C++ versions --- CMakeLists.txt | 2 +- src/File.C | 1 - src/File.h | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5a677f8..e498566 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.21 FATAL_ERROR) project(minisat) -set(CMAKE_CXX_STANDARD 11) +set(CMAKE_CXX_STANDARD 17) #-------------------------------------------------------------------------------------------------- # Configurable options: diff --git a/src/File.C b/src/File.C index b31ca92..8f24a29 100644 --- a/src/File.C +++ b/src/File.C @@ -119,7 +119,6 @@ void putUInt(File& out, uint64 val) uint64 getUInt(File& in) - throw(Exception_EOF) { uint byte0, byte1, byte2, byte3, byte4, byte5, byte6, byte7; byte0 = in.getChar(); diff --git a/src/File.h b/src/File.h index c97d653..d7060f5 100644 --- a/src/File.h +++ b/src/File.h @@ -129,7 +129,7 @@ public: void putUInt (File& out, uint64 val); -uint64 getUInt (File& in) throw(Exception_EOF); +uint64 getUInt (File& in); static inline uint64 encode64(int64 val) { return (val >= 0) ? (uint64)val << 1 : (((uint64)(~val) << 1) | 1); } static inline int64 decode64(uint64 val) { return ((val & 1) == 0) ? (int64)(val >> 1) : ~(int64)(val >> 1); } static inline void putInt (File& out, int64 val) { putUInt(out, encode64(val)); }