Skip to content

Conversation

@N-Dekker
Copy link
Contributor

Removed `constexpr itk::Index` variables initialized by zero's, that were only
there as the index argument of a region initialization.

Follow-up to pull request InsightSoftwareConsortium#5627
commit f9885d2
"STYLE: Remove `T::IndexType index{}` from region initialization in tests"
@github-actions github-actions bot added type:Testing Ensure that the purpose of a class is met/the results on a wide set of test cases are correct area:Core Issues affecting the Core module area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module area:Registration Issues affecting the Registration module area:Numerics Issues affecting the Numerics module labels Nov 16, 2025
Removed `IndexType` variables initialized by zero's (`{ 0, ..., 0 }`), that were
only there as the index argument of a region initialization.

Using Notepad++, Replace in Files (Search Mode: Regular expression), doing:

  Find what: `^( [ ]+)constexpr IndexType[ ]+(\w+){[0, ]*};[\r\n]+\1(.*[rR]egion.* \w+)\(\2, (.*)\);$`
  Find what: `^( [ ]+)constexpr IndexType[ ]+(\w+){[0, ]*};[\r\n]+\1(.*[rR]egion.* \w+){ \2, (.*) }];$`
  Find what: `^( [ ]+)constexpr IndexType[ ]+(\w+){[0, ]*};[\r\n]+\1(.*[rR]egion.* \w+) = { \2, (.*) };$`

  Replace with: $1$3{ $4 };

Manually fixed itkCenteredVersorTransformInitializerTest.cxx compile errors
after removing `index`. Removed `IndexType` that have become unused with this
commit.

Follow-up to pull request InsightSoftwareConsortium#5627
commit f9885d2
"STYLE: Remove `T::IndexType index{}` from region initialization in tests"
@N-Dekker N-Dekker force-pushed the Remove-itk-Index-from-region-initialization-in-tests branch from 2b2faec to 495d45b Compare November 17, 2025 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:Core Issues affecting the Core module area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module area:Numerics Issues affecting the Numerics module area:Registration Issues affecting the Registration module type:Testing Ensure that the purpose of a class is met/the results on a wide set of test cases are correct

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants