I was trying to refactor Ultrasound remote module to avoid nodiscard
warnings, only to end up with non-compiling code. The error messages are below. @Niels_Dekker I assume that some recent transform physical point overloads should be added to Ultrasound?
Build started...
1>------ Build started: Project: swig, Configuration: RelWithDebInfo x64 ------
2>------ Build started: Project: castxml, Configuration: RelWithDebInfo x64 ------
3>------ Build started: Project: UltrasoundHeaderTestClean, Configuration: RelWithDebInfo x64 ------
4>------ Skipped Build: Project: RUN_TESTS, Configuration: RelWithDebInfo x64 ------
4>Project not selected to build for this solution configuration
5>------ Skipped Build: Project: NightlyMemoryCheck, Configuration: RelWithDebInfo x64 ------
5>Project not selected to build for this solution configuration
6>------ Skipped Build: Project: Nightly, Configuration: RelWithDebInfo x64 ------
6>Project not selected to build for this solution configuration
7>------ Build started: Project: ITKData, Configuration: RelWithDebInfo x64 ------
8>------ Skipped Build: Project: Experimental, Configuration: RelWithDebInfo x64 ------
8>Project not selected to build for this solution configuration
9>------ Skipped Build: Project: Continuous, Configuration: RelWithDebInfo x64 ------
9>Project not selected to build for this solution configuration
10>------ Build started: Project: ClangFormat, Configuration: RelWithDebInfo x64 ------
11>------ Build started: Project: UltrasoundTestDriver, Configuration: RelWithDebInfo x64 ------
12>------ Build started: Project: UltrasoundHeaderTest1, Configuration: RelWithDebInfo x64 ------
13>------ Build started: Project: UltrasoundCastXML, Configuration: RelWithDebInfo x64 ------
14>------ Skipped Build: Project: ITKHeaderTests, Configuration: RelWithDebInfo x64 ------
14>Project not selected to build for this solution configuration
12>Generating test/UltrasoundHeaderTest1.cxx
12>UltrasoundHeaderTest1.cxx
11>itkBlockMatchingBayesianRegularizationDisplacementCalculatorTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkAnalyticSignalImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
12>UltrasoundHeaderTest1.vcxproj -> C:\Dev\ITK-py11\Wrapping\Generators\Python\itk\UltrasoundHeaderTest1.exe
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(148,1): message : while compiling class template member function 'void itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingBayesianRegularizationDisplacementCalculatorTest.cxx(61,40): message : see reference to class template instantiation 'itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11> with
11> [
11> TValue=itk::ImageBase<2>::SpacingValueType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>itkBlockMatchingImageRegistrationMethodTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkAttenuationImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(148,1): message : while compiling class template member function 'void itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingImageRegistrationMethodTest.cxx(57,40): message : see reference to class template instantiation 'itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11> with
11> [
11> TValue=itk::ImageBase<2>::SpacingValueType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>itkBlockMatchingMultiResolutionImageRegistrationMethodTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkBModeImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,13): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(90,1): message : while compiling class template member function 'void itk::BlockMatching::MultiResolutionFixedSearchRegionImageSource<InputImageType,InputImageType,DisplacementImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingMultiResolutionImageRegistrationMethodTest.cxx(68,52): message : see reference to class template instantiation 'itk::BlockMatching::MultiResolutionFixedSearchRegionImageSource<InputImageType,InputImageType,DisplacementImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11> with
11> [
11> T=itk::SpacePrecisionType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11> with
11> [
11> TValue=itk::ImageBase<2>::SpacingValueType
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11> with
11> [
11> T=itk::ImageBase<2>::SpacingValueType,
11> TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11> ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,13): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>Generating Code...
11>Done building project "UltrasoundTestDriver.vcxproj" -- FAILED.
Build has been canceled.
========== Elapsed 12:26 PM ==========