convert_hex_to_binary(): Remove exception specification
authorThomas Jarosch <thomas.jarosch@intra2net.com>
Mon, 20 May 2024 10:43:46 +0000 (12:43 +0200)
committerThomas Jarosch <thomas.jarosch@intra2net.com>
Thu, 1 Aug 2024 12:40:40 +0000 (14:40 +0200)
gcc complained:
"ISO C++17 does not allow dynamic exception specifications"

Also remove it in ensure_indent_level() static function.

src/stringfunc.cpp
src/stringfunc.hxx
src/tracefunc.cpp

index 7108bc9..c6050f4 100644 (file)
@@ -498,7 +498,6 @@ std::string convert_binary_to_hex(
 std::string convert_hex_to_binary(
    const std::string& str
 )
-throw (std::runtime_error)
 {
    std::string result;
    char c= 0;
index 06d85f9..d8f286d 100644 (file)
@@ -185,7 +185,7 @@ std::string join_string(
 
 std::string convert_binary_to_hex(const std::string&str, bool upper_case_digits= false);
 
-std::string convert_hex_to_binary(const std::string& str) throw(std::runtime_error);
+std::string convert_hex_to_binary(const std::string& str);
 
 
 /*
index bad392d..a4e26b6 100644 (file)
@@ -90,7 +90,6 @@ static PerThreadContainer *TLS_get_container() throw ()
  * @param level the desired indent level.
  */
 static void ensure_indent_level(PerThreadContainer *per_thread, unsigned int level)
-                       throw(std::length_error, std::bad_alloc)
 {
     // First initialization?
     if (per_thread->indents.empty())