diff --git a/src/storage.cc b/src/storage.cc index 9c75a40d9..e01317983 100644 --- a/src/storage.cc +++ b/src/storage.cc @@ -66,7 +66,7 @@ void Storage::InitBuyPolicyParameters() { if ((active_buying_min == -1) || (active_buying_max == -1)) { throw cyclus::ValueError("Invalid active buying frequency range. Please provide both a min and max value."); } - active_dist_ = cyclus::UniformIntDist>(new cyclus::UniformIntDist(active_buying_min, active_buying_max)); + active_dist_ = cyclus::UniformIntDist::Ptr (new cyclus::UniformIntDist(active_buying_min, active_buying_max)); } else if (active_buying_frequency_type == "Normal") { if ((active_buying_mean == -1) || (active_buying_stddev == -1)) { @@ -76,7 +76,7 @@ void Storage::InitBuyPolicyParameters() { if (active_buying_max == -1) { active_buying_max = std::numeric_limits::max();} - active_dist_ = cyclus::NormalIntDist>(new cyclus::NormalIntDist(active_buying_mean, active_buying_stddev, + active_dist_ = cyclus::NormalIntDist::Ptr (new cyclus::NormalIntDist(active_buying_mean, active_buying_stddev, active_buying_min, active_buying_max)); } else { @@ -84,13 +84,13 @@ void Storage::InitBuyPolicyParameters() { /// set up dormant buying distribution if (dormant_buying_frequency_type == "Fixed") { - dormant_dist_ = cyclus::FixedIntDist>(new cyclus::FixedIntDist(dormant_buying_val)); + dormant_dist_ = cyclus::FixedIntDist::Ptr (new cyclus::FixedIntDist(dormant_buying_val)); } else if (dormant_buying_frequency_type == "Uniform") { if ((dormant_buying_min == -1) || (dormant_buying_max == -1)) { throw cyclus::ValueError("Invalid dormant buying frequency range. Please provide both a min and max value."); } - dormant_dist_ = cyclus::UniformIntDist>(new cyclus::UniformIntDist(dormant_buying_min, dormant_buying_max)); + dormant_dist_ = cyclus::UniformIntDist::Ptr (new cyclus::UniformIntDist(dormant_buying_min, dormant_buying_max)); } else if (dormant_buying_frequency_type == "Normal") { if ((dormant_buying_mean == -1) || (dormant_buying_stddev == -1)) { @@ -99,7 +99,7 @@ void Storage::InitBuyPolicyParameters() { if (dormant_buying_min == -1) {dormant_buying_min = 1;} if (dormant_buying_max == -1) { dormant_buying_max = std::numeric_limits::max();} - dormant_dist_ = cyclus::NormalIntDist>(new cyclus::NormalIntDist(dormant_buying_mean, dormant_buying_stddev, + dormant_dist_ = cyclus::NormalIntDist::Ptr (new cyclus::NormalIntDist(dormant_buying_mean, dormant_buying_stddev, dormant_buying_min, dormant_buying_max)); } else { @@ -107,13 +107,13 @@ void Storage::InitBuyPolicyParameters() { /// set up buying size distribution if (buying_size_type == "Fixed") { - size_dist_ = cyclus::FixedDoubleDist>(new cyclus::FixedDoubleDist(buying_size_val)); + size_dist_ = cyclus::FixedDoubleDist::Ptr (new cyclus::FixedDoubleDist(buying_size_val)); } else if (buying_size_type == "Uniform") { if ((buying_size_min == -1) || (buying_size_max == -1)) { throw cyclus::ValueError("Invalid buying size range. Please provide both a min and max value."); } - size_dist_ = cyclus::UniformDoubleDist>(new cyclus::UniformDoubleDist(buying_size_min, buying_size_max)); + size_dist_ = cyclus::UniformDoubleDist::Ptr (new cyclus::UniformDoubleDist(buying_size_min, buying_size_max)); } else if (buying_size_type == "Normal") { if ((buying_size_mean == -1) || (buying_size_stddev == -1)) { @@ -121,7 +121,7 @@ void Storage::InitBuyPolicyParameters() { } if (buying_size_min == -1) {buying_size_min = 0;} if (buying_size_max == -1) {buying_size_max = 1;} - size_dist_ = cyclus::NormalDoubleDist>(new cyclus::NormalDoubleDist(buying_size_mean, buying_size_stddev, + size_dist_ = cyclus::NormalDoubleDist::Ptr (new cyclus::NormalDoubleDist(buying_size_mean, buying_size_stddev, buying_size_min, buying_size_max)); } else {