mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-09-08 21:33:55 +00:00
Make deprecated tags more descriptive
Also, test to make sure that the deprecated types are still valid.
This commit is contained in:
parent
b92566cdd1
commit
05fc1747e0
@ -221,7 +221,10 @@ public:
|
||||
const vtkm::cont::ArrayHandle<vtkm::Id, OffsetsStorageTag>& offsets);
|
||||
|
||||
template <typename Device, typename VisitTopology, typename IncidentTopology>
|
||||
struct VTKM_DEPRECATED(1.6, "Use ExecConnectivityType.") ExecutionTypes
|
||||
struct VTKM_DEPRECATED(
|
||||
1.6,
|
||||
"Replace ExecutionTypes<D, V, I>::ExecObjectType with ExecConnectivityType<V, I>.")
|
||||
ExecutionTypes
|
||||
{
|
||||
private:
|
||||
VTKM_IS_DEVICE_ADAPTER_TAG(Device);
|
||||
|
@ -106,7 +106,10 @@ public:
|
||||
IncidentTopology>::ExecConnectivityType;
|
||||
|
||||
template <typename DeviceAdapter, typename VisitTopology, typename IncidentTopology>
|
||||
struct VTKM_DEPRECATED(1.6, "Use ExecConnectivityType.") ExecutionTypes
|
||||
struct VTKM_DEPRECATED(
|
||||
1.6,
|
||||
"Replace ExecutionTypes<D, V, I>::ExecObjectType with ExecConnectivityType<V, I>.")
|
||||
ExecutionTypes
|
||||
{
|
||||
using ExecObjectType = ExecConnectivityType<VisitTopology, IncidentTopology>;
|
||||
};
|
||||
|
@ -449,7 +449,10 @@ public:
|
||||
PermutationArrayHandleType>::ExecConnectivityType;
|
||||
|
||||
template <typename Device, typename VisitTopology, typename IncidentTopology>
|
||||
struct VTKM_DEPRECATED(1.6, "Use ExecConnectivityType.") ExecutionTypes
|
||||
struct VTKM_DEPRECATED(
|
||||
1.6,
|
||||
"Replace ExecutionTypes<D, V, I>::ExecObjectType with ExecConnectivityType<V, I>.")
|
||||
ExecutionTypes
|
||||
{
|
||||
using ExecObjectType = ExecConnectivityType<VisitTopology, IncidentTopology>;
|
||||
};
|
||||
|
@ -113,7 +113,9 @@ public:
|
||||
vtkm::exec::ConnectivityStructured<VisitTopology, IncidentTopology, Dimension>;
|
||||
|
||||
template <typename DeviceAdapter, typename VisitTopology, typename IncidentTopology>
|
||||
struct VTKM_DEPRECATED(1.6, "Provide a vtkm::cont::Token object when calling PrepareForInput.")
|
||||
struct VTKM_DEPRECATED(
|
||||
1.6,
|
||||
"Replace ExecutionTypes<D, V, I>::ExecObjectType with ExecConnectivityType<V, I>.")
|
||||
ExecutionTypes
|
||||
{
|
||||
VTKM_IS_DEVICE_ADAPTER_TAG(DeviceAdapter);
|
||||
|
@ -77,6 +77,16 @@ struct OtherType<vtkm::Int32>
|
||||
template <class DeviceAdapterTag>
|
||||
struct TestingArrayHandles
|
||||
{
|
||||
// Make sure deprecated types still work (while applicable)
|
||||
VTKM_DEPRECATED_SUPPRESS_BEGIN
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::ArrayHandle<vtkm::Id>::ReadPortalType,
|
||||
typename vtkm::cont::ArrayHandle<vtkm::Id>::template ExecutionTypes<
|
||||
DeviceAdapterTag>::PortalConst>::value));
|
||||
VTKM_STATIC_ASSERT((std::is_same<typename vtkm::cont::ArrayHandle<vtkm::Id>::WritePortalType,
|
||||
typename vtkm::cont::ArrayHandle<vtkm::Id>::
|
||||
template ExecutionTypes<DeviceAdapterTag>::Portal>::value));
|
||||
VTKM_DEPRECATED_SUPPRESS_END
|
||||
|
||||
template <typename PortalType>
|
||||
struct PortalExecObjectWrapper : vtkm::cont::ExecutionObjectBase
|
||||
|
@ -19,6 +19,84 @@
|
||||
#include <vtkm/cont/CellSetStructured.h>
|
||||
#include <vtkm/cont/testing/Testing.h>
|
||||
|
||||
// Make sure deprecated types still work (while applicable)
|
||||
VTKM_DEPRECATED_SUPPRESS_BEGIN
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetStructured<3>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagPoint, vtkm::TopologyElementTagCell>,
|
||||
typename vtkm::cont::CellSetStructured<3>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagPoint,
|
||||
vtkm::TopologyElementTagCell>::ExecObjectType>::value));
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetStructured<3>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagCell, vtkm::TopologyElementTagPoint>,
|
||||
typename vtkm::cont::CellSetStructured<3>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagCell,
|
||||
vtkm::TopologyElementTagPoint>::ExecObjectType>::value));
|
||||
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetExplicit<>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagPoint, vtkm::TopologyElementTagCell>,
|
||||
typename vtkm::cont::CellSetExplicit<>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagPoint,
|
||||
vtkm::TopologyElementTagCell>::ExecObjectType>::value));
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetExplicit<>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagCell, vtkm::TopologyElementTagPoint>,
|
||||
typename vtkm::cont::CellSetExplicit<>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagCell,
|
||||
vtkm::TopologyElementTagPoint>::ExecObjectType>::value));
|
||||
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetSingleType<>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagPoint, vtkm::TopologyElementTagCell>,
|
||||
typename vtkm::cont::CellSetSingleType<>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagPoint,
|
||||
vtkm::TopologyElementTagCell>::ExecObjectType>::value));
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetSingleType<>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagCell, vtkm::TopologyElementTagPoint>,
|
||||
typename vtkm::cont::CellSetSingleType<>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagCell,
|
||||
vtkm::TopologyElementTagPoint>::ExecObjectType>::value));
|
||||
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetPermutation<vtkm::cont::CellSetExplicit<>>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagPoint, vtkm::TopologyElementTagCell>,
|
||||
typename vtkm::cont::CellSetPermutation<vtkm::cont::CellSetExplicit<>>::
|
||||
ExecutionTypes<vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagPoint,
|
||||
vtkm::TopologyElementTagCell>::ExecObjectType>::value));
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetPermutation<vtkm::cont::CellSetExplicit<>>::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagCell, vtkm::TopologyElementTagPoint>,
|
||||
typename vtkm::cont::CellSetPermutation<vtkm::cont::CellSetExplicit<>>::
|
||||
ExecutionTypes<vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagCell,
|
||||
vtkm::TopologyElementTagPoint>::ExecObjectType>::value));
|
||||
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetExtrude::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagPoint, vtkm::TopologyElementTagCell>,
|
||||
typename vtkm::cont::CellSetExtrude::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagPoint,
|
||||
vtkm::TopologyElementTagCell>::ExecObjectType>::value));
|
||||
VTKM_STATIC_ASSERT(
|
||||
(std::is_same<typename vtkm::cont::CellSetExtrude::
|
||||
ExecConnectivityType<vtkm::TopologyElementTagCell, vtkm::TopologyElementTagPoint>,
|
||||
typename vtkm::cont::CellSetExtrude::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial,
|
||||
vtkm::TopologyElementTagCell,
|
||||
vtkm::TopologyElementTagPoint>::ExecObjectType>::value));
|
||||
VTKM_DEPRECATED_SUPPRESS_END
|
||||
|
||||
namespace
|
||||
{
|
||||
|
||||
|
@ -71,7 +71,7 @@ public:
|
||||
typename vtkm::cont::ArrayHandle<vtkm::IdComponent>::ReadPortalType>;
|
||||
|
||||
template <typename Device>
|
||||
struct VTKM_DEPRECATED(1.6, "Use ExecLookup.") ExecutionTypes
|
||||
struct VTKM_DEPRECATED(1.6, "Replace ExecutionTypes<D>::Lookup with ExecLookup.") ExecutionTypes
|
||||
{
|
||||
using Lookup = ExecLookup;
|
||||
};
|
||||
@ -194,7 +194,7 @@ public:
|
||||
typename vtkm::cont::ArrayHandle<vtkm::IdComponent>::ReadPortalType>;
|
||||
|
||||
template <typename Device>
|
||||
struct VTKM_DEPRECATED(1.6, "Use ExecLookup.") ExecutionTypes
|
||||
struct VTKM_DEPRECATED(1.6, "Replace ExecutionTypes<D>::Lookup with ExecLookup.") ExecutionTypes
|
||||
{
|
||||
using Lookup = ExecLookup;
|
||||
};
|
||||
|
@ -14,6 +14,16 @@
|
||||
|
||||
#include <vtkm/cont/testing/Testing.h>
|
||||
|
||||
// Make sure deprecated types still work (while applicable)
|
||||
VTKM_DEPRECATED_SUPPRESS_BEGIN
|
||||
VTKM_STATIC_ASSERT((std::is_same<typename vtkm::worklet::internal::KeysBase::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial>::Lookup,
|
||||
typename vtkm::worklet::internal::KeysBase::ExecLookup>::value));
|
||||
VTKM_STATIC_ASSERT((std::is_same<typename vtkm::worklet::Keys<vtkm::Id>::ExecutionTypes<
|
||||
vtkm::cont::DeviceAdapterTagSerial>::Lookup,
|
||||
typename vtkm::worklet::Keys<vtkm::Id>::ExecLookup>::value));
|
||||
VTKM_DEPRECATED_SUPPRESS_END
|
||||
|
||||
namespace
|
||||
{
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user