ITKContourInterpolation icon indicating copy to clipboard operation
ITKContourInterpolation copied to clipboard

COMP: Use modern macro for name of class

Open hjmjohnson opened this issue 11 months ago • 8 comments

When preparing for the future with ITK by setting ITK_FUTURE_LEGACY_REMOVE:BOOL=ON ITK_LEGACY_REMOVEBOOL=ON

The future preferred macro should be used │ - itkTypeMacro │ + itkOverrideGetNameOfClassMacro

hjmjohnson avatar Jan 25 '25 17:01 hjmjohnson

@dzenanz This is part of an effort to create a v5.4.2.1 release that allows Slicer to build with ITK_LEGACY_REMOVE and ITK_FUTURE_LEGACY_REMOVE turned on.

It is an intermediate refactoring that is upstream compatible but allows Slicer to catch up more slowly.

hjmjohnson avatar Jan 25 '25 17:01 hjmjohnson

@dzenanz Part of the future updates needed to build Slicer with future code recommendationsl

hjmjohnson avatar Jan 25 '25 19:01 hjmjohnson

This sounds like WASM part needs to be updated to use a newer base image:

In file included from /work/wasm/morphological-contour-interpolation.cxx:24:
/work/include/itkMorphologicalContourInterpolator.h:83:3: error: unknown type name 'itkOverrideGetNameOfClassMacro'
   83 |   itkOverrideGetNameOfClassMacro(MorphologicalContourInterpolator);
      |   ^
1 error generated.

dzenanz avatar Jan 28 '25 16:01 dzenanz

Is itkOverrideGetNameOfClassMacro in the release-5.4 branch?

thewtex avatar Jan 28 '25 21:01 thewtex

Yes, it was added in Dec 2023.

dzenanz avatar Jan 28 '25 22:01 dzenanz

It is there already in v5.4.0: https://github.com/InsightSoftwareConsortium/ITK/blob/v5.4.0/Modules/Core/Common/include/itkMacro.h#L463

dzenanz avatar Jan 28 '25 22:01 dzenanz

I will rebase, follow-up.

thewtex avatar Jan 30 '25 17:01 thewtex

Can you rebase this Hans?

dzenanz avatar Feb 22 '25 16:02 dzenanz

@dzenanz Rebased.

hjmjohnson avatar Mar 14 '25 12:03 hjmjohnson

Matt, would changes from https://github.com/InsightSoftwareConsortium/ITKMeshToPolyData/pull/77 work here?

dzenanz avatar Mar 14 '25 15:03 dzenanz

Wasm updates for ITK 5.4.2 are here: https://github.com/KitwareMedical/ITKContourInterpolation/pull/130

thewtex avatar Mar 14 '25 15:03 thewtex