[Insight-developers] Test programs that won't compile

Joshua Cates cates@cayenne.cs.utah.edu
Tue, 28 Nov 2000 11:39:50 -0700 (MST)


Fixed itkRandomImageSource.  Only required the addition of a few
typename's here and there (hopefully not stepping on anyone's toes by
doing that).  Unfortunately it looks like itkWriteVTKImage is also broken.
Can't easily tell what's wrong there.

I've checked in a new version of itkUUImageToImageFilterDriver.h which
avoids using those two classes altogether and should allow these test
programs (excepting itkNeighborhoodOperatorTest) to compile. You may or
may not get warnings associated with the use of itk::Scalar and the way
the compiler implicitly overloads itk::Scalar's operators.

Josh.

+--+--+--+--+--+--+--+--+--+--+--+--
 Josh Cates			
 Department of Computer Science	
 University of Utah
 Email: cates@cs.utah.edu
 Phone: (801) 587-7697
 URL:   www.cs.utk.edu/~cates
--+--+--+--+--+--+--+--+--+--+--+---

On Tue, 28 Nov 2000, Paul Hughett wrote:

> 
> Attempting to compile itkFilterImageAnisotropicDiffusionTest, last
> updated on Monday morning, using gcc 2.95.2 under Linux yields the
> following error messages:
> 
> c++  -g -O2   -I/home/hughett/work/Insight -I/home/hughett/work/Insight/Code/Insight3DParty/vxl -I/home/hughett/work/Insight/Code/Common -I/home/hughett/work/Insight/Code/Insight3DParty/vxl    -c itkFilterImageAnisotropicDiffusionTest.cxx -o itkFilterImageAnisotropicDiffusionTest.o
> In file included from itkUUImageToImageFilterDriver.h:24,
>                  from itkFilterImageAnisotropicDiffusionTest.cxx:20:
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:100: parse error before `)'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: `TOutputImage::ScalarValueType' is not a valid declarator
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107:   perhaps you want `typename TOutputImage::ScalarValueType' to make it a type
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: parse error before `('
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: syntax error before `<'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: invalid use of member `itk::RandomImageSource<TOutputImage>::itkmsg'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids declaration `itkmsgbuff' with no type
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids initialization of member `itkmsgbuff'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: making `itkmsgbuff' static
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids in-class initialization of non-const static member `itkmsgbuff'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids declaration `OutputWindowDisplayText' with no type
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids initialization of member `OutputWindowDisplayText'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: making `OutputWindowDisplayText' static
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: ANSI C++ forbids in-class initialization of non-const static member `OutputWindowDisplayText'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: syntax error before `.'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h: In method `void itk::RandomImageSource<TOutputImage>::SetMin(...)':
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:101: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:101:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:101: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:101:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102: to refer to a type member of a template parameter,
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:102:   use `typename TOutputImage::ScalarValueType'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h: At top level:
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:107: parse error at null character
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: `TOutputImage' was not declared in this scope
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: parse error before `::'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: virtual outside class declaration
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h: In function `void SetMax(...)':
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: invalid use of `this' in non-member function
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: `Object' undeclared (first use this function)
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: (Each undeclared identifier is reported only once
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: for each function it appears in.)
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: parse error before `::'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: invalid use of `this' in non-member function
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: invalid use of `this' in non-member function
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: invalid use of `this' in non-member function
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: invalid use of `this' in non-member function
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: `_arg' undeclared (first use this function)
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: `itkmsgbuff' undeclared (first use this function)
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: implicit declaration of function `int OutputWindowDisplayText(...)'
> /home/hughett/work/Insight/Code/Common/itkRandomImageSource.h:113: confused by earlier errors, bailing out
> make: *** [itkFilterImageAnisotropicDiffusionTest.o] Error 1
>