From bbf6a682281076d2e067fab5de2a00d42a8dd9b5 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Wed, 15 Jan 2014 23:04:38 +0100 Subject: [PATCH] Workaround another g++-4.0.1 bug on Darwin. * src/ltlast/formula_tree.hh: Mark nodes with SPOT_API. --- src/ltlast/formula_tree.hh | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/src/ltlast/formula_tree.hh b/src/ltlast/formula_tree.hh index 4cf946f32..92b0c0833 100644 --- a/src/ltlast/formula_tree.hh +++ b/src/ltlast/formula_tree.hh @@ -1,5 +1,5 @@ // -*- coding: utf-8 -*- -// Copyright (C) 2009, 2012, 2013 Laboratoire de Recherche et +// Copyright (C) 2009, 2012, 2013, 2014 Laboratoire de Recherche et // Développement de l'Epita (LRDE). // // This file is part of Spot, a model checking library. @@ -37,38 +37,41 @@ namespace spot /// Trees representing formulae where atomic propositions are unknown. namespace formula_tree { - struct node + // These struct should not need to be made public using + // SPOT_API, unfortunately dynamic_cast<> with g++-4.0.1 fails + // on Darwin if we do not. + struct SPOT_API node { virtual ~node() {}; }; /// We use boost::shared_ptr to easily handle deletion. typedef boost::shared_ptr node_ptr; - struct node_unop : node + struct SPOT_API node_unop : node { unop::type op; node_ptr child; }; - struct node_binop : node + struct SPOT_API node_binop : node { binop::type op; node_ptr lhs; node_ptr rhs; }; - struct node_multop : node + struct SPOT_API node_multop : node { multop::type op; node_ptr lhs; node_ptr rhs; }; - struct node_nfa : node + struct SPOT_API node_nfa : node { std::vector children; spot::ltl::nfa::ptr nfa; }; /// Integer values for True and False used in node_atomic. enum { True = -1, False = -2 }; - struct node_atomic : node + struct SPOT_API node_atomic : node { int i; };