Skip to content

Commit

Permalink
fixup: simplify deprecated sparse Cajita wrappers
Browse files Browse the repository at this point in the history
  • Loading branch information
streeve committed Nov 20, 2023
1 parent e798c39 commit 25f7411
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 23 deletions.
7 changes: 0 additions & 7 deletions grid/src/Cabana_Grid_IndexSpace.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -501,13 +501,6 @@ CAJITA_DEPRECATED auto createView( Args&&... args )
return Cabana::Grid::createView( std::forward<Args>( args )... );
}

template <class Scalar, class... Params>
CAJITA_DEPRECATED auto createView( const std::string& label,
const IndexSpace<1>& index_space )
{
return Cabana::Grid::createView<Scalar, Params...>( label, index_space );
}

template <class... Args>
CAJITA_DEPRECATED auto createSubview( Args&&... args )
{
Expand Down
26 changes: 10 additions & 16 deletions grid/src/Cabana_Grid_SparseArray.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -721,38 +721,32 @@ using SparseArrayLayout CAJITA_DEPRECATED =
Cabana::Grid::Experimental::SparseArrayLayout<DataTypes, EntityType,
MeshType, SparseMapType>;

template <class DataTypes, class EntityType, class MeshType,
class SparseMapType>
CAJITA_DEPRECATED auto createSparseArrayLayout(
const std::string label,
SparseArrayLayout<DataTypes, EntityType, MeshType, SparseMapType>& layout )
template <class... Args>
CAJITA_DEPRECATED auto createSparseArrayLayout( Args&&... args )
{
return Cabana::Grid::Experimental::createSparseArrayLayout( label, layout );
return Cabana::Grid::Experimental::createSparseArrayLayout(
std::forward<Args>( args )... );
}

template <class T>
using is_sparse_array_layout CAJITA_DEPRECATED =
Cabana::Grid::Experimental::is_sparse_array_layout<T>;

template <class DataTypes, class DeviceType, class EntityType, class MeshType,
template <class DataTypes, class MemorySpace, class EntityType, class MeshType,
class SparseMapType>
using SparseArray CAJITA_DEPRECATED =
Cabana::Grid::Experimental::SparseArray<DataTypes, DeviceType, EntityType,
Cabana::Grid::Experimental::SparseArray<DataTypes, MemorySpace, EntityType,
MeshType, SparseMapType>;

template <class T>
using is_sparse_array CAJITA_DEPRECATED =
Cabana::Grid::Experimental::is_sparse_array<T>;

template <class DeviceType, class DataTypes, class EntityType, class MeshType,
class SparseMapType>
CAJITA_DEPRECATED auto
createSparseArray( const std::string label,
SparseArray<DataTypes, DeviceType, EntityType, MeshType,
SparseMapType>& layout )
template <class MemorySpace, class... Args>
CAJITA_DEPRECATED auto createSparseArray( Args&&... args )
{
return Cabana::Grid::Experimental::createSparseArray<DeviceType>( label,
layout );
return Cabana::Grid::Experimental::createSparseArray<MemorySpace>(
std::forward<Args>( args )... );
}
//! \endcond
} // namespace Experimental
Expand Down

0 comments on commit 25f7411

Please sign in to comment.