diff options
author | Mathias Preiner <mathias.preiner@gmail.com> | 2021-03-16 10:56:01 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-16 10:56:01 -0700 |
commit | d6890791897ddebf1212d3e3147bf7aeb2415b27 (patch) | |
tree | 51c69ba48a7550b6a7660e2488b4b39cbedba539 /src/parser/parser.h | |
parent | 0d3ea6f2dcaf80d386c7765ee8a708c18e3ed574 (diff) |
cmake: Generate cvc4_export.h and set visibility to hidden. (#6139)
The build system (cmake) will automatically generate an export header
cvc4_export.h, which makes sure that the correct export features are
defined depending on the compiler and target platform. The macro CVC4_EXPORT
replaces CVC4_PUBLIC and its usage is reduced by 2/3.
Co-authored-by: Gereon Kremer <nafur42@gmail.com>
Diffstat (limited to 'src/parser/parser.h')
-rw-r--r-- | src/parser/parser.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/parser/parser.h b/src/parser/parser.h index 7789fd148..c2fad6656 100644 --- a/src/parser/parser.h +++ b/src/parser/parser.h @@ -24,6 +24,7 @@ #include <string> #include "api/cvc4cpp.h" +#include "cvc4_export.h" #include "expr/kind.h" #include "expr/symbol_manager.h" #include "expr/symbol_table.h" @@ -56,7 +57,7 @@ enum DeclarationCheck { * Returns a string representation of the given object (for * debugging). */ -inline std::ostream& operator<<(std::ostream& out, DeclarationCheck check) CVC4_PUBLIC; +inline std::ostream& operator<<(std::ostream& out, DeclarationCheck check); inline std::ostream& operator<<(std::ostream& out, DeclarationCheck check) { switch(check) { case CHECK_NONE: @@ -84,7 +85,7 @@ enum SymbolType { * Returns a string representation of the given object (for * debugging). */ -inline std::ostream& operator<<(std::ostream& out, SymbolType type) CVC4_PUBLIC; +inline std::ostream& operator<<(std::ostream& out, SymbolType type); inline std::ostream& operator<<(std::ostream& out, SymbolType type) { switch(type) { case SYM_VARIABLE: @@ -101,7 +102,8 @@ inline std::ostream& operator<<(std::ostream& out, SymbolType type) { * name of the file, line number and column information, and in-scope * declarations. */ -class CVC4_PUBLIC Parser { +class CVC4_EXPORT Parser +{ friend class ParserBuilder; private: @@ -769,7 +771,7 @@ public: * c1, c2, c3 are digits from 0 to 7. */ std::vector<unsigned> processAdHocStringEsc(const std::string& s); -};/* class Parser */ +}; /* class Parser */ }/* CVC4::parser namespace */ }/* CVC4 namespace */ |