Skip to content

Commit

Permalink
Trac #33981: latte_int: ExponentialSubst.h:62:3: error: ISO C++17 doe…
Browse files Browse the repository at this point in the history
…s not allow dynamic exception specifications

{{{
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CC   --mode=compile gcc
-DHAVE_CONFIG_H -DEXEEXT=\"\" -I. -I../../code     -g -O2 -c -o
xreadlink.lo xreadlink.c
[latte_int-1.7.6] libtool: compile:  gcc -DHAVE_CONFIG_H -DEXEEXT=\"\"
-I. -I../../code -g -O2 -c xreadlink.c  -fPIC -DPIC -o .libs/xreadlink.o
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CC   --mode=link gcc
-g -O2  -no-undefined  -Wl,-rpath-
link,/var/lib/buildbot/slave/sage_git/build/local/lib
-L/var/lib/buildbot/slave/sage_git/build/local/lib
-Wl,-rpath,/var/lib/buildbot/slave/sage_git/build/local/lib -Wl,-rpath-
link,/var/lib/buildbot/slave/sage_git/build/local/lib
-L/var/lib/buildbot/slave/sage_git/build/local/lib
-Wl,-rpath,/var/lib/buildbot/slave/sage_git/build/local/lib  -o
libgnu.la  allocator.lo areadlink.lo careadlinkat.lo exitfail.lo
malloca.lo progname.lo unistd.lo xmalloc.lo xalloc-die.lo xreadlink.lo
[latte_int-1.7.6] libtool: link: ar cru .libs/libgnu.a .libs/allocator.o
.libs/areadlink.o .libs/careadlinkat.o .libs/exitfail.o .libs/malloca.o
.libs/progname.o .libs/unistd.o .libs/xmalloc.o .libs/xalloc-die.o
.libs/xreadlink.o
[latte_int-1.7.6] ar: `u' modifier ignored since `D' is the default (see
`U')
[latte_int-1.7.6] libtool: link: ranlib .libs/libgnu.a
[latte_int-1.7.6] libtool: link: ( cd ".libs" && rm -f "libgnu.la" && ln
-s "../libgnu.la" "libgnu.la" )
[latte_int-1.7.6] Making all in latte
[latte_int-1.7.6] Making all in .
[latte_int-1.7.6] g++ -DHAVE_CONFIG_H -I. -I../../code  -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include  -g -O2 -c -o
maximize.o maximize.cpp
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CXX   --mode=compile
g++ -DHAVE_CONFIG_H -I. -I../../code  -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include  -g -O2 -c -o
barvinok/dec.lo barvinok/dec.cpp
[latte_int-1.7.6] libtool: compile:  g++ -DHAVE_CONFIG_H -I.
-I../../code -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include -g -O2 -c
barvinok/dec.cpp  -fPIC -DPIC -o barvinok/.libs/dec.o
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CXX   --mode=compile
g++ -DHAVE_CONFIG_H -I. -I../../code  -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include  -g -O2 -c -o
barvinok/barvinok.lo barvinok/barvinok.cpp
[latte_int-1.7.6] libtool: compile:  g++ -DHAVE_CONFIG_H -I.
-I../../code -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include -g -O2 -c
barvinok/barvinok.cpp  -fPIC -DPIC -o barvinok/.libs/barvinok.o
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CXX   --mode=compile
g++ -DHAVE_CONFIG_H -I. -I../../code  -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include  -g -O2 -c -o
barvinok/ComputeOmega.lo barvinok/ComputeOmega.cpp
[latte_int-1.7.6] libtool: compile:  g++ -DHAVE_CONFIG_H -I.
-I../../code -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include -g -O2 -c
barvinok/ComputeOmega.cpp  -fPIC -DPIC -o barvinok/.libs/ComputeOmega.o
[latte_int-1.7.6] /bin/bash ../../libtool  --tag=CXX   --mode=compile
g++ -DHAVE_CONFIG_H -I. -I../../code  -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include  -g -O2 -c -o
count.lo count.cpp
[latte_int-1.7.6] libtool: compile:  g++ -DHAVE_CONFIG_H -I.
-I../../code -I../../code
-DINSTALLDIR=\"/var/lib/buildbot/slave/sage_git/build/local/bin\"
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-I/var/lib/buildbot/slave/sage_git/build/local/include
-D__STDC_LIMIT_MACROS -D_4ti2_GMP_
-I/var/lib/buildbot/slave/sage_git/build/local/include -g -O2 -c
count.cpp  -fPIC -DPIC -o .libs/count.o
[latte_int-1.7.6] In file included from count.h:35,
[latte_int-1.7.6]                  from count.cpp:26:
[latte_int-1.7.6] ExponentialSubst.h:62:3: error: ISO C++17 does not
allow dynamic exception specifications
[latte_int-1.7.6]    62 |   throw(NotGenericException);
[latte_int-1.7.6]       |   ^~~~~
[latte_int-1.7.6] ExponentialSubst.h:67:3: error: ISO C++17 does not
allow dynamic exception specifications
[latte_int-1.7.6]    67 |   throw(NotGenericException);
[latte_int-1.7.6]       |   ^~~~~
[latte_int-1.7.6] Makefile:2442: recipe for target 'count.lo' failed
[latte_int-1.7.6] make[7]: *** [count.lo] Error 1
[latte_int-1.7.6] Makefile:2502: recipe for target 'all-recursive'
failed
[latte_int-1.7.6] make[6]: *** [all-recursive] Error 1
[latte_int-1.7.6] Makefile:841: recipe for target 'all-recursive' failed
[latte_int-1.7.6] make[5]: *** [all-recursive] Error 1
[latte_int-1.7.6] Makefile:778: recipe for target 'all' failed
[latte_int-1.7.6] make[4]: *** [all] Error 2
[latte_int-1.7.6] Makefile:912: recipe for target 'all-recursive' failed
[latte_int-1.7.6] make[3]: *** [all-recursive] Error 1
[latte_int-1.7.6] ******************************************************
**************************
[latte_int-1.7.6] Error building latte_int-1.7.6
[latte_int-1.7.6] ******************************************************
**************************
}}}
See also latte-int/latte#24

URL: https://trac.sagemath.org/33981
Reported by: vbraun
Ticket author(s): Matthias Koeppe
Reviewer(s): John Palmieri
  • Loading branch information
Release Manager committed Sep 19, 2022
2 parents 787b4be + 57aff70 commit 97beeae
Showing 1 changed file with 79 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
From 6dbf7f07d5c9e1f3afe793f782d191d4465088ae Mon Sep 17 00:00:00 2001
From: Matthias Koeppe <mkoeppe@math.ucdavis.edu>
Date: Thu, 7 Jul 2022 15:42:35 -0700
Subject: [PATCH] Remove dynamic exception specifications to conform to ISO
C++17

---
code/latte/ExponentialSubst.cpp | 2 --
code/latte/ExponentialSubst.h | 6 ++----
code/latte/sqlite/IntegrationDB.cpp | 2 +-
code/latte/sqlite/IntegrationDB.h | 2 +-
4 files changed, 4 insertions(+), 8 deletions(-)

diff --git a/code/latte/ExponentialSubst.cpp b/code/latte/ExponentialSubst.cpp
index a839b820..bcbfa934 100644
--- a/code/latte/ExponentialSubst.cpp
+++ b/code/latte/ExponentialSubst.cpp
@@ -57,7 +57,6 @@ mpq_vector
computeExponentialResidueWeights(const vec_ZZ &generic_vector,
mpz_class &prod_ray_scalar_products,
const listCone *cone, int numOfVars)
- throw(NotGenericException)
{
// Compute dimension; can be smaller than numOfVars
int dimension = 0;
@@ -95,7 +94,6 @@ computeExponentialResidueWeights(const vec_ZZ &generic_vector,
mpq_vector
computeExponentialResidueWeights(const vec_ZZ &generic_vector,
const listCone *cone, int numOfVars)
- throw(NotGenericException)
{
mpz_class prod_ray_scalar_products;
return computeExponentialResidueWeights(generic_vector,
diff --git a/code/latte/ExponentialSubst.h b/code/latte/ExponentialSubst.h
index c9fa4ace..43a4ab63 100644
--- a/code/latte/ExponentialSubst.h
+++ b/code/latte/ExponentialSubst.h
@@ -58,13 +58,11 @@ class Exponential_Single_Cone_Parameters
mpq_vector /* FIXME: This version can probably go away */
computeExponentialResidueWeights(const vec_ZZ &generic_vector,
mpz_class &prod_ray_scalar_products,
- const listCone *cone, int numOfVars)
- throw(NotGenericException);
+ const listCone *cone, int numOfVars);

mpq_vector
computeExponentialResidueWeights(const vec_ZZ &generic_vector,
- const listCone *cone, int numOfVars)
- throw(NotGenericException);
+ const listCone *cone, int numOfVars);

ZZ
scalar_power(const vec_ZZ &generic_vector,
diff --git a/code/latte/sqlite/IntegrationDB.cpp b/code/latte/sqlite/IntegrationDB.cpp
index ab8df535..c1dde830 100644
--- a/code/latte/sqlite/IntegrationDB.cpp
+++ b/code/latte/sqlite/IntegrationDB.cpp
@@ -1277,7 +1277,7 @@ void IntegrationDB::insertSpecficPolytopeIntegrationTest(string polymakeFile, i
* @parm filePath: to the latte-style polynomial.
* @return rowid of the inserted row.
*/
-int IntegrationDB::insertPolynomial(int dim, int degree, const char*filePath) throw(SqliteDBexception)
+int IntegrationDB::insertPolynomial(int dim, int degree, const char*filePath)
{
if ( doesPolynomialExist(filePath))
throw SqliteDBexception(string("insertPolynomial::Polynomial ")+filePath+" already exist");
diff --git a/code/latte/sqlite/IntegrationDB.h b/code/latte/sqlite/IntegrationDB.h
index d690a832..ce8cfac6 100644
--- a/code/latte/sqlite/IntegrationDB.h
+++ b/code/latte/sqlite/IntegrationDB.h
@@ -67,7 +67,7 @@ class IntegrationDB: public SqliteDB
int insertIntegrationTest(int polynomialID, int polytopeID);
void insertIntegrationTest(int dim, int degree, int vertexCount, int count);
void insertSpecficPolytopeIntegrationTest(string polymakeFile, int degree, int count);
- int insertPolynomial(int dim, int degree, const char*filePath) throw(SqliteDBexception);
+ int insertPolynomial(int dim, int degree, const char*filePath);

int insertPolytope(int dim, int vertexCount, int simple, int dualRowID, const char* latteFilePath, const char* polymakeFilePath);

0 comments on commit 97beeae

Please sign in to comment.