From: Tim King Date: Mon, 18 Sep 2017 06:40:17 +0000 (-0700) Subject: Moving the CVC4_PUBLIC attribute to the beginning of operator++. (#1107) X-Git-Tag: cvc5-1.0.0~5633 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=053003a64bde91aa32f688d248d83c3d4f271250;p=cvc5.git Moving the CVC4_PUBLIC attribute to the beginning of operator++. (#1107) Removes the following warning when compiling with gcc version 4.8.4 : ../../../../../src/expr/kind_template.h:95:55: warning: '__visibility__' attribute ignored on non-class types [-Wattributes] Tested with clang-3.5. --- diff --git a/src/expr/kind_template.h b/src/expr/kind_template.h index 0a6b7bc61..170f51df1 100644 --- a/src/expr/kind_template.h +++ b/src/expr/kind_template.h @@ -92,8 +92,8 @@ ${theory_enum} const TheoryId THEORY_FIRST = static_cast(0); const TheoryId THEORY_SAT_SOLVER = THEORY_LAST; -inline TheoryId& CVC4_PUBLIC operator ++ (TheoryId& id) { - return id = static_cast(((int)id) + 1); +CVC4_PUBLIC inline TheoryId& operator++(TheoryId& id) { + return id = static_cast(static_cast(id) + 1); } std::ostream& operator<<(std::ostream& out, TheoryId theoryId);