From fa5dc424956cae58ec910bee49e1b9118fc1feb0 Mon Sep 17 00:00:00 2001 From: Luca Fedeli Date: Tue, 8 Aug 2023 01:55:13 +0200 Subject: Clang-tidy CI test: add 4 new readability checks (#4163) --- Source/Initialization/PlasmaInjector.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Source/Initialization/PlasmaInjector.cpp') diff --git a/Source/Initialization/PlasmaInjector.cpp b/Source/Initialization/PlasmaInjector.cpp index 115fbfca1..03cee4c5e 100644 --- a/Source/Initialization/PlasmaInjector.cpp +++ b/Source/Initialization/PlasmaInjector.cpp @@ -50,7 +50,7 @@ namespace { std::string string; stringstream << var << " string '" << name << "' not recognized."; string = stringstream.str(); - WARPX_ABORT_WITH_MESSAGE(string.c_str()); + WARPX_ABORT_WITH_MESSAGE(string); } } @@ -688,16 +688,16 @@ void PlasmaInjector::parseMomentum (const amrex::ParmParse& pp) ux_min, uy_min, uz_min, ux_max, uy_max, uz_max)); } else if (mom_dist_s == "maxwell_boltzmann"){ h_mom_temp = std::make_unique(pp); - const GetTemperature getTemp(*h_mom_temp.get()); + const GetTemperature getTemp(*h_mom_temp); h_mom_vel = std::make_unique(pp); - const GetVelocity getVel(*h_mom_vel.get()); + const GetVelocity getVel(*h_mom_vel); // Construct InjectorMomentum with InjectorMomentumBoltzmann. h_inj_mom.reset(new InjectorMomentum((InjectorMomentumBoltzmann*)nullptr, getTemp, getVel)); } else if (mom_dist_s == "maxwell_juttner"){ h_mom_temp = std::make_unique(pp); - const GetTemperature getTemp(*h_mom_temp.get()); + const GetTemperature getTemp(*h_mom_temp); h_mom_vel = std::make_unique(pp); - const GetVelocity getVel(*h_mom_vel.get()); + const GetVelocity getVel(*h_mom_vel); // Construct InjectorMomentum with InjectorMomentumJuttner. h_inj_mom.reset(new InjectorMomentum((InjectorMomentumJuttner*)nullptr, getTemp, getVel)); } else if (mom_dist_s == "radial_expansion") { -- cgit v1.2.3