Commit 9e642707 authored by David C. Lonie's avatar David C. Lonie

Remove __int64 cases, assume 'long long' is available.

While this branch was being developed, __int64 was removed
and all supported compilers now provide 'long long'.

See fcd6444a.
parent e4c4919c
......@@ -103,30 +103,17 @@ set(vtkArrayDispatch_all_types
"float"
"int"
"long"
"long long"
"short"
"signed char"
"unsigned char"
"unsigned int"
"unsigned long"
"unsigned long long"
"unsigned short"
"vtkIdType"
)
if(VTK_TYPE_USE_LONG_LONG)
list(APPEND vtkArrayDispatch_all_types
"long long"
"unsigned long long"
)
endif()
if(VTK_TYPE_USE___INT64)
list(APPEND vtkArrayDispatch_all_types
"__int64"
"unsigned __int64"
)
endif()
# For each container, define a header and a list of types:
if (VTK_DISPATCH_AOS_ARRAYS)
list(APPEND vtkArrayDispatch_containers vtkAOSDataArrayTemplate)
......
......@@ -30,11 +30,13 @@ add_data_array_test(vtkDoubleArray vtkDoubleArray.h "double" vtkDoubleArray)
add_data_array_test(vtkFloatArray vtkFloatArray.h "float" vtkFloatArray)
add_data_array_test(vtkIntArray vtkIntArray.h "int" vtkIntArray)
add_data_array_test(vtkLongArray vtkLongArray.h "long" vtkLongArray)
add_data_array_test(vtkLongLongArray vtkLongLongArray.h "long long" vtkLongLongArray)
add_data_array_test(vtkShortArray vtkShortArray.h "short" vtkShortArray)
add_data_array_test(vtkSignedCharArray vtkSignedCharArray.h "signed char" vtkSignedCharArray)
add_data_array_test(vtkUnsignedCharArray vtkUnsignedCharArray.h "unsigned char" vtkUnsignedCharArray)
add_data_array_test(vtkUnsignedIntArray vtkUnsignedIntArray.h "unsigned int" vtkUnsignedIntArray)
add_data_array_test(vtkUnsignedLongArray vtkUnsignedLongArray.h "unsigned long" vtkUnsignedLongArray)
add_data_array_test(vtkUnsignedLongLongArray vtkUnsignedLongLongArray.h "unsigned long long" vtkUnsignedLongLongArray)
add_data_array_test(vtkUnsignedShortArray vtkUnsignedShortArray.h "unsigned short" vtkUnsignedShortArray)
add_data_array_test(vtkIdTypeArray vtkIdTypeArray.h "vtkIdType" vtkIdTypeArray)
set(value_types
......@@ -43,27 +45,17 @@ set(value_types
float
int
long
"long long"
short
"signed char"
"unsigned char"
"unsigned int"
"unsigned long"
"unsigned long long"
"unsigned short"
vtkIdType
)
if(VTK_TYPE_USE_LONG_LONG)
add_data_array_test(vtkLongLongArray vtkLongLongArray.h "long long" vtkLongLongArray)
add_data_array_test(vtkUnsignedLongLongArray vtkUnsignedLongLongArray.h "unsigned long long" vtkUnsignedLongLongArray)
set(value_types ${value_types} "long long" "unsigned long long")
endif()
if(VTK_TYPE_USE___INT64)
add_data_array_test(vtk__Int64Array vtk__Int64Array.h "__int64" vtk__Int64Array)
add_data_array_test(vtkUnsigned__Int64Array vtkUnsigned__Int64Array.h "unsigned __int64" vtkUnsigned__Int64Array)
set(value_types ${value_types} "__int64" "unsigned __int64")
endif()
# Templated data array subclasses can be done in a loop:
foreach(value_type ${value_types})
string(REPLACE " " "_" pretty_value_type "${value_type}")
......
......@@ -2904,40 +2904,28 @@ int ExerciseDataArray()
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, vtkIdType>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, int>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, long long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, short>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, signed char>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned char>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned int>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned short>();
#ifdef VTK_TYPE_USE_LONG_LONG
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, long long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned long long>();
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, __int64>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned __int64>();
#endif // VTK_TYPE_USE___INT64
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkAbstractArray, unsigned short>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, char>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, float>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, double>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, vtkIdType>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, int>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, long long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, short>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, signed char>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned char>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned int>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned short>();
#ifdef VTK_TYPE_USE_LONG_LONG
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, long long>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned long long>();
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, __int64>();
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned __int64>();
#endif // VTK_TYPE_USE___INT64
errors += Test_void_DeepCopy_array<ScalarT, ArrayT, vtkDataArray, unsigned short>();
errors += Test_void_InterpolateTuple_i_indices_source_weights<ScalarT, ArrayT>();
errors += Test_void_InterpolateTuple_i_id1_source1_id2_source2_t<ScalarT, ArrayT>();
errors += Test_int_Resize_numTuples<ScalarT, ArrayT>();
......
......@@ -37,23 +37,15 @@
#include "vtkIdTypeArray.h"
#include "vtkIntArray.h"
#include "vtkLongArray.h"
#include "vtkLongLongArray.h"
#include "vtkShortArray.h"
#include "vtkSignedCharArray.h"
#include "vtkSOADataArrayTemplate.h"
#include "vtkUnsignedCharArray.h"
#include "vtkUnsignedIntArray.h"
#include "vtkUnsignedLongArray.h"
#include "vtkUnsignedShortArray.h"
#ifdef VTK_TYPE_USE_LONG_LONG
#include "vtkLongLongArray.h"
#include "vtkUnsignedLongLongArray.h"
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
#include "vtk__Int64Array.h"
#include "vtkUnsigned__Int64Array.h"
#endif // VTK_TYPE_USE___INT64
#include "vtkUnsignedShortArray.h"
// About this test:
//
......@@ -90,21 +82,15 @@ int TestGenericDataArrayAPI(int, char *[])
errors += ExerciseGenericDataArray<float, vtkFloatArray>();
errors += ExerciseGenericDataArray<int, vtkIntArray>();
errors += ExerciseGenericDataArray<long, vtkLongArray>();
errors += ExerciseGenericDataArray<long long, vtkLongLongArray>();
errors += ExerciseGenericDataArray<short, vtkShortArray>();
errors += ExerciseGenericDataArray<signed char, vtkSignedCharArray>();
errors += ExerciseGenericDataArray<unsigned char, vtkUnsignedCharArray>();
errors += ExerciseGenericDataArray<unsigned int, vtkUnsignedIntArray>();
errors += ExerciseGenericDataArray<unsigned long, vtkUnsignedLongArray>();
errors += ExerciseGenericDataArray<unsigned long long, vtkUnsignedLongLongArray>();
errors += ExerciseGenericDataArray<unsigned short, vtkUnsignedShortArray>();
errors += ExerciseGenericDataArray<vtkIdType, vtkIdTypeArray>();
#ifdef VTK_TYPE_USE_LONG_LONG
errors += ExerciseGenericDataArray<long long, vtkLongLongArray>();
errors += ExerciseGenericDataArray<unsigned long long, vtkUnsignedLongLongArray>();
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE__INT64
errors += ExerciseGenericDataArray<__int64, vtk__Int64Array>();
errors += ExerciseGenericDataArray<unsigned __int64, vtkUnsigned__Int64Array>();
#endif // VTK_TYPE_USE___INT64
// Explicit AoS arrays:
errors += ExerciseGenericDataArray<char, vtkAOSDataArrayTemplate<char> >();
......@@ -112,21 +98,15 @@ int TestGenericDataArrayAPI(int, char *[])
errors += ExerciseGenericDataArray<float, vtkAOSDataArrayTemplate<float> >();
errors += ExerciseGenericDataArray<int, vtkAOSDataArrayTemplate<int> >();
errors += ExerciseGenericDataArray<long, vtkAOSDataArrayTemplate<long> >();
errors += ExerciseGenericDataArray<long long, vtkAOSDataArrayTemplate<long long> >();
errors += ExerciseGenericDataArray<short, vtkAOSDataArrayTemplate<short> >();
errors += ExerciseGenericDataArray<signed char, vtkAOSDataArrayTemplate<signed char> >();
errors += ExerciseGenericDataArray<unsigned char, vtkAOSDataArrayTemplate<unsigned char> >();
errors += ExerciseGenericDataArray<unsigned int, vtkAOSDataArrayTemplate<unsigned int> >();
errors += ExerciseGenericDataArray<unsigned long, vtkAOSDataArrayTemplate<unsigned long> >();
errors += ExerciseGenericDataArray<unsigned long long, vtkAOSDataArrayTemplate<unsigned long long> >();
errors += ExerciseGenericDataArray<unsigned short, vtkAOSDataArrayTemplate<unsigned short> >();
errors += ExerciseGenericDataArray<vtkIdType, vtkAOSDataArrayTemplate<vtkIdType> >();
#ifdef VTK_TYPE_USE_LONG_LONG
errors += ExerciseGenericDataArray<long long, vtkAOSDataArrayTemplate<long long> >();
errors += ExerciseGenericDataArray<unsigned long long, vtkAOSDataArrayTemplate<unsigned long long> >();
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
errors += ExerciseGenericDataArray<__int64, vtkAOSDataArrayTemplate<__int64> >();
errors += ExerciseGenericDataArray<unsigned __int64, vtkAOSDataArrayTemplate<unsigned __int64> >();
#endif // VTK_TYPE_USE___INT64
// Explicit SoA arrays:
errors += ExerciseGenericDataArray<char, vtkSOADataArrayTemplate<char> >();
......@@ -134,21 +114,15 @@ int TestGenericDataArrayAPI(int, char *[])
errors += ExerciseGenericDataArray<float, vtkSOADataArrayTemplate<float> >();
errors += ExerciseGenericDataArray<int, vtkSOADataArrayTemplate<int> >();
errors += ExerciseGenericDataArray<long, vtkSOADataArrayTemplate<long> >();
errors += ExerciseGenericDataArray<long long, vtkSOADataArrayTemplate<long long> >();
errors += ExerciseGenericDataArray<short, vtkSOADataArrayTemplate<short> >();
errors += ExerciseGenericDataArray<signed char, vtkSOADataArrayTemplate<signed char> >();
errors += ExerciseGenericDataArray<unsigned char, vtkSOADataArrayTemplate<unsigned char> >();
errors += ExerciseGenericDataArray<unsigned int, vtkSOADataArrayTemplate<unsigned int> >();
errors += ExerciseGenericDataArray<unsigned long, vtkSOADataArrayTemplate<unsigned long> >();
errors += ExerciseGenericDataArray<unsigned long long, vtkSOADataArrayTemplate<unsigned long long> >();
errors += ExerciseGenericDataArray<unsigned short, vtkSOADataArrayTemplate<unsigned short> >();
errors += ExerciseGenericDataArray<vtkIdType, vtkSOADataArrayTemplate<vtkIdType> >();
#ifdef VTK_TYPE_USE_LONG_LONG
errors += ExerciseGenericDataArray<long long, vtkSOADataArrayTemplate<long long> >();
errors += ExerciseGenericDataArray<unsigned long long, vtkSOADataArrayTemplate<unsigned long long> >();
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
errors += ExerciseGenericDataArray<__int64, vtkSOADataArrayTemplate<__int64> >();
errors += ExerciseGenericDataArray<unsigned __int64, vtkSOADataArrayTemplate<unsigned __int64> >();
#endif // VTK_TYPE_USE___INT64
if (errors > 0)
{
......
......@@ -268,20 +268,14 @@ extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(double);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(float);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(int);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(long);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(short);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(signed char);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned char);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned int);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
#ifdef VTK_TYPE_USE_LONG_LONG
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long long);
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(__int64);
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned __int64);
#endif // VTK_TYPE_USE___INT64
extern VTK_AOS_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
#pragma warning (pop)
......
......@@ -139,35 +139,13 @@ namespace vtkArrayDispatch {
// A TypeList containing all real ValueTypes.
typedef vtkTypeList_Create_2(double, float) Reals;
// Build a list of all compiler supported integral types:
namespace impl {
typedef vtkTypeList::Unique<
vtkTypeList_Create_10(char, int, long, short, signed char, unsigned char,
unsigned int, unsigned long, unsigned short, vtkIdType)
>::Result BaseIntegrals;
#ifdef VTK_TYPE_USE_LONG_LONG
typedef vtkTypeList_Create_2(long long, unsigned long long) LongLongIntegrals;
#else // VTK_TYPE_USE_LONG_LONG
typedef vtkTypeList::NullType LongLongIntegrals;
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
typedef vtkTypeList_Create_2(__int64, unsigned __int64) I64Integrals;
#else // VTK_TYPE_USE___INT64
typedef vtkTypeList::NullType I64Integrals;
#endif // VTK_TYPE_USE___INT64
typedef vtkTypeList::Append<LongLongIntegrals,
I64Integrals>::Result ExtraIntegrals;
typedef vtkTypeList::Append<BaseIntegrals,
ExtraIntegrals>::Result AllIntegrals;
} // end impl namespace
// Description:
// A Typelist containing all integral ValueTypes.
typedef impl::AllIntegrals Integrals;
typedef vtkTypeList::Unique<
vtkTypeList_Create_12(char, int, long, long long, short, signed char,
unsigned char, unsigned int, unsigned long,
unsigned long long, unsigned short, vtkIdType)
>::Result Integrals;
// Description:
// A Typelist containing all standard VTK array ValueTypes.
......
......@@ -234,20 +234,14 @@ extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(double);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(float);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(int);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(short);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(signed char);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned char);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned int);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
#ifdef VTK_TYPE_USE_LONG_LONG
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long long);
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(__int64);
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned __int64);
#endif // VTK_TYPE_USE___INT64
extern VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
#pragma warning (pop)
......
......@@ -27,19 +27,11 @@ VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(double);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(float);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(int);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(short);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(signed char);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned char);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned int);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
#ifdef VTK_TYPE_USE_LONG_LONG
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(long long);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned long long);
#endif // VTK_TYPE_USE_LONG_LONG
#ifdef VTK_TYPE_USE___INT64
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned __int64);
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(__int64);
#endif // VTK_TYPE_USE___INT64
VTK_SOA_DATA_ARRAY_TEMPLATE_INSTANTIATE(unsigned short);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment