From: Miller, James V (Research) <millerjv@cr...> - 2002-10-03 16:45:04
ITK got bit a few times when executing code to print out
an ivar (defined by a template parameter) when the template
parameter was an eight bit int. The some streams implementations
would show this as a "character" instead of a small integer.
This caused all kinds of problems in the testing because
the program could unwittingly output a ^S or an EOF, etc.
We ended up added a "PrintType" to our NumericTraits class so
we could safely write
std::cout << static_cast<typename NumericTraits<SomeType>::PrintType>(someVariable)
> deprecate vxl_int_8, vxl_sint_8, vxl_uint_8:
> (As Peter pointed out) these are normally defined
> to be char so
> vcl_cout << (vxl_int_8)(65) << vcl_endl;
> displays 'A' not 65. This is not int behaviour.
> I also prefer vxl_byte over vxl_uint_8, and for
> consistency vxl_sbyte over vxl_int_8.