Skip to content

Remove local type aliases of ImageRegionIterator and ImageRegionConstIterator in *.hxx files#5981

Draft
N-Dekker wants to merge 2 commits intoInsightSoftwareConsortium:mainfrom
N-Dekker:Remove-local-type-aliases-of-ImageRegionIterator
Draft

Remove local type aliases of ImageRegionIterator and ImageRegionConstIterator in *.hxx files#5981
N-Dekker wants to merge 2 commits intoInsightSoftwareConsortium:mainfrom
N-Dekker:Remove-local-type-aliases-of-ImageRegionIterator

Conversation

@N-Dekker
Copy link
Contributor

Made it easier to figure out which kind of iterator is being used.

Using Notepad++, Replace in Files, doing:

    Find what: ^[ ]+ using (\w+) = (ImageRegionIterator<\w+>);\r\n(.*?[^\w])\1
    Replace with: $3$2
    Filters: itk*.hxx
    [v] Match case
    (*) Regular expression
    [v] . matches newline

Followed by manual replacements of uses of those type aliases.
@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:Registration Issues affecting the Registration module area:Segmentation Issues affecting the Segmentation module area:Video Issues affecting the Video module area:Numerics Issues affecting the Numerics module labels Mar 25, 2026
Made it easier to figure out which kind of iterator is being used.

Using Notepad++, Replace in Files, doing:

    Find what: ^[ ]+ using (\w+) = (ImageRegionConstIterator<\w+>);\r\n(.*?[^\w])\1
    Replace with: $3$2
    Filters: itk*.hxx
    [v] Match case
    (*) Regular expression
    [v] . matches newline

Followed by manual replacements of uses of those type aliases.
@N-Dekker N-Dekker force-pushed the Remove-local-type-aliases-of-ImageRegionIterator branch from 94b5802 to 901ea16 Compare March 25, 2026 18:10
Copy link
Member

@dzenanz dzenanz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally looking good. For this approach (remove definitions then fix if compiler complains) it is important to have non-default modules (review, video, FEM, GPU, etc.) turned on.

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:Numerics Issues affecting the Numerics module area:Registration Issues affecting the Registration module area:Segmentation Issues affecting the Segmentation module area:Video Issues affecting the Video 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