Skip to content

Commit

Permalink
Merge pull request cyclus#1611 from bennibbelink/boost-warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
gonuke authored Oct 22, 2023
2 parents 018ee48 + c36a762 commit 00b4c4d
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 17 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ Since last release
* Issue #1312. (#1560)
* fix sell_policy that was offering bids when capacity was inbetween 0 and the
quantize, bids that one was not able to fullfill and caused cyclus to crash. (#1552)
* Deprecation warnings involving <boost/detail/sp_typeinfo.hpp> (#1611)



Expand Down
2 changes: 0 additions & 2 deletions src/agent.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
#include <string>
#include <vector>

#include <boost/shared_ptr.hpp>

#include "db_init.h"
#include "dynamic_module.h"
#include "infile_tree.h"
Expand Down
24 changes: 12 additions & 12 deletions src/any.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ original Boost 1.54.0
#include <boost/static_assert.hpp>
#include <boost/mpl/bool.hpp>
#include <boost/assert.hpp>
#include <boost/detail/sp_typeinfo.hpp>
#include <boost/core/typeinfo.hpp>

#include <stdexcept>
#include <typeinfo>
Expand All @@ -74,7 +74,7 @@ namespace boost { namespace spirit
struct bad_any_cast
: std::bad_cast
{
bad_any_cast(boost::detail::sp_typeinfo const& src, boost::detail::sp_typeinfo const& dest)
bad_any_cast(boost::core::typeinfo const& src, boost::core::typeinfo const& dest)
: from(src.name()), to(dest.name())
{}

Expand All @@ -90,7 +90,7 @@ namespace boost { namespace spirit
template <typename Char>
struct fxn_ptr_table
{
boost::detail::sp_typeinfo const& (*get_type)();
boost::core::typeinfo const& (*get_type)();
void (*static_delete)(void**);
void (*destruct)(void**);
void (*clone)(void* const*, void**);
Expand All @@ -107,9 +107,9 @@ namespace boost { namespace spirit
template<typename T, typename Char>
struct type
{
static boost::detail::sp_typeinfo const& get_type()
static boost::core::typeinfo const& get_type()
{
return BOOST_SP_TYPEID(T);
return BOOST_CORE_TYPEID(T);
}
static void static_delete(void** x)
{
Expand Down Expand Up @@ -138,9 +138,9 @@ namespace boost { namespace spirit
template<typename T, typename Char>
struct type
{
static boost::detail::sp_typeinfo const& get_type()
static boost::core::typeinfo const& get_type()
{
return BOOST_SP_TYPEID(T);
return BOOST_CORE_TYPEID(T);
}
static void static_delete(void** x)
{
Expand Down Expand Up @@ -300,16 +300,16 @@ namespace boost { namespace spirit
return *this;
}

boost::detail::sp_typeinfo const& type() const
boost::core::typeinfo const& type() const
{
return table->get_type();
}

template <typename T>
T const& cast() const
{
if (type() != BOOST_SP_TYPEID(T))
throw bad_any_cast(type(), BOOST_SP_TYPEID(T));
if (type() != BOOST_CORE_TYPEID(T))
throw bad_any_cast(type(), BOOST_CORE_TYPEID(T));

return spirit::detail::get_table<T>::is_small::value ?
*reinterpret_cast<T const*>(&object) :
Expand Down Expand Up @@ -359,7 +359,7 @@ namespace boost { namespace spirit
template <typename T, typename Char>
inline T* any_cast (basic_hold_any<Char>* operand)
{
if (operand && operand->type() == BOOST_SP_TYPEID(T)) {
if (operand && operand->type() == BOOST_CORE_TYPEID(T)) {
return spirit::detail::get_table<T>::is_small::value ?
reinterpret_cast<T*>(&operand->object) :
reinterpret_cast<T*>(operand->object);
Expand Down Expand Up @@ -390,7 +390,7 @@ namespace boost { namespace spirit

nonref* result = any_cast<nonref>(&operand);
if(!result)
boost::throw_exception(bad_any_cast(operand.type(), BOOST_SP_TYPEID(T)));
boost::throw_exception(bad_any_cast(operand.type(), BOOST_CORE_TYPEID(T)));
return *result;
}

Expand Down
2 changes: 1 addition & 1 deletion src/exchange_graph.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
#include <utility>
#include <vector>

#include <boost/shared_ptr.hpp>
#include <boost/weak_ptr.hpp>
#include <boost/shared_ptr.hpp>

namespace cyclus {

Expand Down
1 change: 1 addition & 0 deletions src/greedy_solver.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#ifndef CYCLUS_SRC_GREEDY_SOLVER_H_
#define CYCLUS_SRC_GREEDY_SOLVER_H_

#include <boost/shared_ptr.hpp>
#include "exchange_graph.h"
#include "exchange_solver.h"
#include "greedy_preconditioner.h"
Expand Down
1 change: 0 additions & 1 deletion src/res_tracker.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

#include <string>
#include <vector>
#include <boost/shared_ptr.hpp>

#include "context.h"
#include "resource.h"
Expand Down
1 change: 1 addition & 0 deletions src/toolkit/symbolic_function_factories.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <string>
#include <map>
#include <sstream>
#include <boost/shared_ptr.hpp>

#include "symbolic_functions.h"

Expand Down
1 change: 0 additions & 1 deletion src/xml_parser.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
#define CYCLUS_SRC_XML_PARSER_H_

#include <sstream>
#include <boost/shared_ptr.hpp>

namespace xmlpp {
class DomParser;
Expand Down
1 change: 1 addition & 0 deletions tests/integ_tests.cc
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <cmath>

#include <gtest/gtest.h>
#include <boost/shared_ptr.hpp>

#include "cyclus.h"
#include "platform.h"
Expand Down

0 comments on commit 00b4c4d

Please sign in to comment.