Closed phcerdan closed 2 years ago
Fix error after raised after updating CI to itk5.3 in #152
In file included from /work/ITK-cp37-cp37m-manylinux2014_x64/Wrapping/itkFrequencyShrinkViaInverseFFTImageFilter.cxx:16:
In file included from /work/include/itkFrequencyShrinkViaInverseFFTImageFilter.h:21:
/work/include/itkShrinkDecimateImageFilter.h:124:17: error: no type named 'enable_if_t' in namespace 'std'
typename std::enable_if_t<std::numeric_limits
/work/include/itkShrinkDecimateImageFilter.h:124:28: error: expected member name or ';' after declaration specifiers
typename std::enable_if_t<std::numeric_limits<TOutputType>::is_integer, TOutputType>
~~~~~~~~~~~~~~~~~~~~~~~~~^
2 errors generated.
I thought ITK transitioned to C++14. Isn't it enabled in the CI? I will change it to the C++11 version
C++14 should be enabled in the CI. Let's see whether this builds.
I think the typename
wasn't needed when using std::enable_if_t. However, I wonder why locally (gcc 12) I don't see this error.
CppReference says that's how enable_if_t
is defined:
template< bool B, class T = void >
using enable_if_t = typename enable_if<B,T>::type;
Everything compiles without issue now, but half the tests segfault.
I don't see it these seg faults locally. @dzenanz could you try to reproduce it locally please?
I cannot reproduce the segfaults locally. Let's merge after the CI finishes.
The segfaults in the CI break the CI's usefulness. #152 is now rebased on master, and it absolutely fails. We should probably fix it.
itk::EnableIf was marked as legacy in itk 5.3