From 66ff530b0f95c2ae84b6c08d30b0c366ccf6ba94 Mon Sep 17 00:00:00 2001 From: dyzheng Date: Sat, 28 Mar 2026 21:15:58 +0800 Subject: [PATCH] Refactor: replace C-style cast with static_cast in read_pp_complete.cpp --- source/source_cell/read_pp_complete.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/source_cell/read_pp_complete.cpp b/source/source_cell/read_pp_complete.cpp index e3b58487bff..6adeca1d2f1 100644 --- a/source/source_cell/read_pp_complete.cpp +++ b/source/source_cell/read_pp_complete.cpp @@ -140,7 +140,7 @@ void Pseudopot_upf::complete_default_atom(Atom_pseudo& pp) if (br) { // force msh to be odd for simpson integration - pp.msh = 2 * (int)((pp.msh + 1) / 2) - 1; // 5 + pp.msh = 2 * static_cast((pp.msh + 1) / 2) - 1; // Use static_cast instead of C-style cast for type safety } else { @@ -161,4 +161,4 @@ void Pseudopot_upf::complete_default_vl(Atom_pseudo& pp) } return; -} \ No newline at end of file +}