Skip to content

Commit

Permalink
enable more clang-tidy checks (#1525)
Browse files Browse the repository at this point in the history
also modernize typedefs
  • Loading branch information
zingale authored Mar 27, 2024
1 parent f47a7fc commit 3112c13
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
2 changes: 0 additions & 2 deletions .clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ Checks: >
-cppcoreguidelines-init-variables,
-cppcoreguidelines-interfaces-global-init,
-cppcoreguidelines-macro-usage,
-cppcoreguidelines-no-malloc,
-cppcoreguidelines-non-private-member-variables-in-classes,
-cppcoreguidelines-owning-memory,
-cppcoreguidelines-pro-*,
Expand All @@ -24,7 +23,6 @@ Checks: >
modernize-*,
-modernize-avoid-c-arrays,
-modernize-use-trailing-return-type,
-modernize-use-using,
performance-*,
-performance-avoid-endl,
portability-*,
Expand Down
6 changes: 3 additions & 3 deletions integration/integrator_data.H
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ constexpr int integrator_neqs ()
return int_neqs;
}

typedef amrex::Array1D<short, 1, INT_NEQS> IArray1D;
typedef amrex::Array1D<amrex::Real, 1, INT_NEQS> RArray1D;
typedef ArrayUtil::MathArray2D<1, INT_NEQS, 1, INT_NEQS> RArray2D;
using IArray1D = amrex::Array1D<short, 1, INT_NEQS>;
using RArray1D = amrex::Array1D<amrex::Real, 1, INT_NEQS>;
using RArray2D = ArrayUtil::MathArray2D<1, INT_NEQS, 1, INT_NEQS>;

#endif
4 changes: 2 additions & 2 deletions interfaces/burn_type.H
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const int net_ienuc = NumSpec + 1;

// this is the data type that is used to get the ydots from the actual
// RHS of the network, regardless of Strang or SDC
typedef amrex::Array1D<amrex::Real, 1, neqs> YdotNetArray1D;
using YdotNetArray1D = amrex::Array1D<amrex::Real, 1, neqs>;

// these indices represent the order that the conserved state comes
// into the ODE integration from the hydro code.
Expand All @@ -58,7 +58,7 @@ const int SVAR_EVOLVE = SFX;
// this is the data type of the dense Jacobian that the network wants.
// it is not the same size as the Jacobian that VODE cares about when
// we are doing simplified-SDC
typedef ArrayUtil::MathArray2D<1, neqs, 1, neqs> JacNetArray2D;
using JacNetArray2D = ArrayUtil::MathArray2D<1, neqs, 1, neqs>;

struct burn_t
{
Expand Down

0 comments on commit 3112c13

Please sign in to comment.