Skip to content

Commit

Permalink
address some cppcoreguidelines-prefer-member-initializer issues
Browse files Browse the repository at this point in the history
  • Loading branch information
lucafedeli88 committed Oct 24, 2024
1 parent 36bc599 commit af29d3a
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -575,10 +575,9 @@ namespace picsar::multi_physics::phys::breit_wheeler
math::zero<RealType>,
math::half<RealType>,
params.chi_phot_how_many, params.frac_how_many,
vals}}
{
m_init_flag = true;
}
vals}},
m_init_flag{true}
{}

/*
* Generates the content of the lookup table (not usable on GPUs).
Expand Down Expand Up @@ -827,9 +826,9 @@ namespace picsar::multi_physics::phys::breit_wheeler

protected:
pair_prod_lookup_table_params<RealType> m_params; /* Table parameters*/
bool m_init_flag = false; /* Initialization flag*/
containers::equispaced_2d_table<
RealType, VectorType> m_table; /* Table data*/
bool m_init_flag = false; /* Initialization flag*/

private:
/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,9 @@ namespace picsar::multi_physics::phys::quantum_sync
m_table{containers::equispaced_1d_table<RealType, VectorType>{
math::m_log(params.chi_part_min),
math::m_log(params.chi_part_max),
vals}}
{
m_init_flag = true;
}
vals}},
m_init_flag{true}
{}

/*
* Generates the content of the lookup table (not usable on GPUs).
Expand Down Expand Up @@ -397,9 +396,9 @@ namespace picsar::multi_physics::phys::quantum_sync

protected:
dndt_lookup_table_params<RealType> m_params; /* Table parameters*/
bool m_init_flag = false; /* Initialization flag*/
containers::equispaced_1d_table<
RealType, VectorType> m_table; /* Table data */
bool m_init_flag = false; /* Initialization flag*/
};

//__________________________________________________________________________
Expand Down Expand Up @@ -531,10 +530,9 @@ namespace picsar::multi_physics::phys::quantum_sync
math::m_log(params.frac_min),
math::m_log(math::one<RealType>),
params.chi_part_how_many, params.frac_how_many,
vals}}
{
m_init_flag = true;
}
vals}},
m_init_flag{true}
{}

/*
* Generates the content of the lookup table (not usable on GPUs).
Expand Down Expand Up @@ -791,9 +789,9 @@ namespace picsar::multi_physics::phys::quantum_sync

protected:
photon_emission_lookup_table_params<RealType> m_params; /* Table parameters*/
bool m_init_flag = false; /* Initialization flag*/
containers::equispaced_2d_table<
RealType, VectorType> m_table; /* Table data*/
bool m_init_flag = false; /* Initialization flag*/
};

//__________________________________________________________________________
Expand Down Expand Up @@ -964,7 +962,7 @@ namespace picsar::multi_physics::phys::quantum_sync
tailopt_photon_emission_lookup_table_params<RealType> params,
VectorType vals):
m_params{params},
m_table{Generic2DTableType<RealType, VectorType>(
m_table{Generic2DTableType<RealType, VectorType>(
params.chi_part_how_many, params.frac_how_many, vals,
detail::LinFunctor<RealType>(
m_params.chi_part_how_many,
Expand All @@ -983,10 +981,9 @@ namespace picsar::multi_physics::phys::quantum_sync
m_params.frac_how_many, m_params.frac_first,
math::m_log(m_params.frac_min),
math::m_log(math::one<RealType>),
math::m_log(m_params.frac_switch)))}
{
m_init_flag = true;
}
math::m_log(m_params.frac_switch)))},
m_init_flag{true}
{}

/**
* Generates the content of the lookup table (not usable on GPUs).
Expand Down Expand Up @@ -1246,9 +1243,8 @@ namespace picsar::multi_physics::phys::quantum_sync

protected:
tailopt_photon_emission_lookup_table_params<RealType> m_params; /* Table parameters*/
bool m_init_flag = false; /* Initialization flag*/
Generic2DTableType<RealType, VectorType> m_table; /* Table data*/

bool m_init_flag = false; /* Initialization flag*/
};

//______________________________________________________________________
Expand Down

0 comments on commit af29d3a

Please sign in to comment.