Skip to content
Snippets Groups Projects
Commit 231218de authored by Sander, Oliver's avatar Sander, Oliver
Browse files

Fix warning about catching polymorphic exception by value

parent bdcd7950
No related branches found
No related tags found
No related merge requests found
...@@ -265,7 +265,7 @@ Func2Tensor setupPrestrainPhase(Python::Module module, int phase){ ...@@ -265,7 +265,7 @@ Func2Tensor setupPrestrainPhase(Python::Module module, int phase){
module.get("phase" + std::to_string(phase) + "_axis").toC<int>(axis); module.get("phase" + std::to_string(phase) + "_axis").toC<int>(axis);
module.get("phase" + std::to_string(phase) + "_angle").toC<double>(angle); module.get("phase" + std::to_string(phase) + "_angle").toC<double>(angle);
} }
catch(Dune::Exception) catch(Dune::Exception&)
{ {
//default frame is used. //default frame is used.
} }
...@@ -329,7 +329,7 @@ Dune::FieldMatrix<double,6,6> setupPhase(Python::Module module, int phase) ...@@ -329,7 +329,7 @@ Dune::FieldMatrix<double,6,6> setupPhase(Python::Module module, int phase)
module.get("phase" + std::to_string(phase) + "_axis").toC<int>(axis); module.get("phase" + std::to_string(phase) + "_axis").toC<int>(axis);
module.get("phase" + std::to_string(phase) + "_angle").toC<double>(angle); module.get("phase" + std::to_string(phase) + "_angle").toC<double>(angle);
} }
catch(Dune::Exception) catch(Dune::Exception& e)
{ {
// std::cout << "(Could not read frame vectors for material phase) " << phase << ": - Canonical Frame (default) is used." << std::endl; // std::cout << "(Could not read frame vectors for material phase) " << phase << ": - Canonical Frame (default) is used." << std::endl;
std::cout << "(Could not read rotation axis & angle for material phase) " << phase << ": - Canonical Frame (default) is used." << std::endl; std::cout << "(Could not read rotation axis & angle for material phase) " << phase << ": - Canonical Frame (default) is used." << std::endl;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment