diff --git a/amr-wind/core/FieldUtils.H b/amr-wind/core/FieldUtils.H index e1391d0066..2028b10773 100644 --- a/amr-wind/core/FieldUtils.H +++ b/amr-wind/core/FieldUtils.H @@ -75,11 +75,7 @@ inline bool is_valid_field_name(const std::string& name) { // Else make sure that our guard is not in the last 8 characters auto found = name.rfind("__FS_"); - if (found != std::string::npos) { - return false; - } - - return true; + return found == std::string::npos; } /** Return an AMReX coarse-to-fine field interpolation object based on diff --git a/amr-wind/core/vs/tensor.H b/amr-wind/core/vs/tensor.H index 88f65fec67..646a9b9e81 100644 --- a/amr-wind/core/vs/tensor.H +++ b/amr-wind/core/vs/tensor.H @@ -25,7 +25,7 @@ struct TensorT using const_iterator = const T*; using Traits = DTraits; - AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE constexpr TensorT() {} + AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE constexpr TensorT() = default; AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE constexpr TensorT( const T& xx, diff --git a/amr-wind/core/vs/vector.H b/amr-wind/core/vs/vector.H index 9660e87227..a5cc667056 100644 --- a/amr-wind/core/vs/vector.H +++ b/amr-wind/core/vs/vector.H @@ -25,7 +25,7 @@ struct VectorT using VType = VectorT; //! Construct a default vector, all components set to zero - AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE VectorT() {} + AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE VectorT() = default; /** New vector given the three components */ diff --git a/amr-wind/utilities/linear_interpolation.H b/amr-wind/utilities/linear_interpolation.H index 2c04b06678..03cdf20318 100644 --- a/amr-wind/utilities/linear_interpolation.H +++ b/amr-wind/utilities/linear_interpolation.H @@ -26,7 +26,8 @@ check_bounds(const It begin, const It end, const T& x) if ((sz < 2) || (x < *begin)) { return Index{0, Limits::LOWLIM}; - } else if (x > *(begin + (sz - 1))) { + } + if (x > *(begin + (sz - 1))) { return Index{sz - 1, Limits::UPLIM}; }