Skip to content

Commit

Permalink
STYLE: Add in-class {} member initializers to 3-letter data members
Browse files Browse the repository at this point in the history
Previous commits that added `{}` initializers to data members by means of
regular expressions had overlooked three-letter identifiers, like `m_E` and
`m_I`.

Follow-up to pull request InsightSoftwareConsortium#3851
commit 5e2c49f
"STYLE: Add in-class `{}` member initializers to objects created by New()"
  • Loading branch information
N-Dekker committed Mar 1, 2023
1 parent 208902e commit ffe5eb6
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Modules/Core/Transform/include/itkKernelTransform.h
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ class ITK_TEMPLATE_EXPORT KernelTransform : public Transform<TParametersValueTyp
bool m_WMatrixComputed{};

/** Identity matrix. */
IMatrixType m_I;
IMatrixType m_I{};

/** The list of source landmarks, denoted 'p'. */
PointSetPointer m_SourceLandmarks{};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ class ITK_TEMPLATE_EXPORT CurvatureNDAnisotropicDiffusionFunction : public Scala
DerivativeOperator<PixelType, Self::ImageDimension> m_DerivativeOperator{};

/** Modified global average gradient magnitude term. */
PixelType m_K;
PixelType m_K{};

/** */
static double m_MIN_NORM;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ class ITK_TEMPLATE_EXPORT GradientNDAnisotropicDiffusionFunction : public Scalar
DerivativeOperator<PixelType, Self::ImageDimension> m_DerivativeOperator{};

/** Modified global average gradient magnitude term. */
PixelType m_K;
PixelType m_K{};

NeighborhoodSizeValueType m_Center{};
NeighborhoodSizeValueType m_Stride[ImageDimension]{};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ class ITK_TEMPLATE_EXPORT VectorGradientNDAnisotropicDiffusionFunction
DerivativeOperator<ScalarValueType, Self::ImageDimension> m_DerivativeOperator{};

/** Modified global average gradient magnitude term. */
ScalarValueType m_K;
ScalarValueType m_K{};

static double m_MIN_NORM;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ class ITK_TEMPLATE_EXPORT GPUGradientNDAnisotropicDiffusionFunction
DerivativeOperator<PixelType, Self::ImageDimension> m_DerivativeOperator{};

/** Modified global average gradient magnitude term. */
PixelType m_K;
PixelType m_K{};

NeighborhoodSizeValueType m_Center{};
NeighborhoodSizeValueType m_Stride[ImageDimension]{};
Expand Down
2 changes: 1 addition & 1 deletion Modules/Numerics/Optimizers/include/itkSPSAOptimizer.h
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ class ITKOptimizers_EXPORT SPSAOptimizer : public SingleValuedNonLinearOptimizer
/** Parameters, as described by Spall.*/
double m_Sa{};
double m_Sc{};
double m_A;
double m_A{};
double m_Alpha{};
double m_Gamma{};
}; // end class SPSAOptimizer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ class ParticleSwarmTestF2 : public SingleValuedCostFunction
}

private:
MatrixType m_A;
MatrixType m_A{};
VectorType m_Intercept{};
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ class ITK_TEMPLATE_EXPORT FEMRegistrationFilter : public ImageToImageFilter<TMov
vnl_vector<unsigned int> m_MeshPixelsPerElementAtEachResolution{};

Float m_TimeStep{ 1 };
vnl_vector<Float> m_E;
vnl_vector<Float> m_E{};
vnl_vector<Float> m_Rho{};
vnl_vector<Float> m_Gamma{};
Float m_Energy{ 0.0 }; // current value of energy
Expand Down

0 comments on commit ffe5eb6

Please sign in to comment.