From: Daniel Arndt Date: Sat, 10 Feb 2018 14:33:28 +0000 (+0100) Subject: Use make_unique/shared in numerics X-Git-Tag: v9.0.0-rc1~425^2~5 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a843a7a5b86a6a44b6f6bf19e0483c6da30a5c86;p=dealii.git Use make_unique/shared in numerics --- diff --git a/include/deal.II/numerics/data_out_dof_data.templates.h b/include/deal.II/numerics/data_out_dof_data.templates.h index f42a8854e8..7b87f62321 100644 --- a/include/deal.II/numerics/data_out_dof_data.templates.h +++ b/include/deal.II/numerics/data_out_dof_data.templates.h @@ -93,11 +93,11 @@ namespace internal break; } if (x_fe_values[i].get() == nullptr) - x_fe_values[i].reset(new dealii::hp::FEValues - (this->mapping_collection, - *this->finite_elements[i], - quadrature, - this->update_flags)); + x_fe_values[i] = std::make_shared> + (this->mapping_collection, + *this->finite_elements[i], + quadrature, + this->update_flags); } } else @@ -118,11 +118,11 @@ namespace internal break; } if (x_fe_face_values[i].get() == nullptr) - x_fe_face_values[i].reset(new dealii::hp::FEFaceValues - (this->mapping_collection, - *this->finite_elements[i], - quadrature, - this->update_flags)); + x_fe_face_values[i] = std::make_shared> + (this->mapping_collection, + *this->finite_elements[i], + quadrature, + this->update_flags); } } @@ -177,11 +177,11 @@ namespace internal break; } if (x_fe_values[i].get() == nullptr) - x_fe_values[i].reset(new dealii::hp::FEValues - (this->mapping_collection, - *this->finite_elements[i], - quadrature, - this->update_flags)); + x_fe_values[i] = std::make_shared> + (this->mapping_collection, + *this->finite_elements[i], + quadrature, + this->update_flags); } } else @@ -201,11 +201,11 @@ namespace internal break; } if (x_fe_face_values[i].get() == nullptr) - x_fe_face_values[i].reset(new dealii::hp::FEFaceValues - (this->mapping_collection, - *this->finite_elements[i], - quadrature, - this->update_flags)); + x_fe_face_values[i] = std::make_shared> + (this->mapping_collection, + *this->finite_elements[i], + quadrature, + this->update_flags); } } } @@ -1327,14 +1327,14 @@ std::vector - (this->dof_data[i]->dof_handler->get_fe_collection())); + finite_elements[i] = std::make_shared> + (this->dof_data[i]->dof_handler->get_fe_collection()); } if (this->dof_data.empty()) { finite_elements.resize(1); - finite_elements[0].reset(new dealii::hp::FECollection - (FE_DGQ(0))); + finite_elements[0] = std::make_shared> + (FE_DGQ(0)); } return finite_elements; }