Skip to content
Snippets Groups Projects
Commit a7ad5aba authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Added Increment type to MeshDimensionsTag

This will be useful for specializations in the subentity layer.
parent 8b5cc911
No related branches found
No related tags found
No related merge requests found
......@@ -40,21 +40,22 @@ namespace Meshes {
template< int Dimension >
class MeshDimensionTag
{
public:
static_assert( Dimensions >= 0, "The value of the dimensions cannot be negative." );
static const int value = Dimension;
public:
static constexpr int value = Dimensions;
typedef MeshDimensionTag< Dimension - 1 > Decrement;
static_assert( value >= 0, "The value of the dimensions cannot be negative." );
using Decrement = MeshDimensionsTag< Dimensions - 1 >;
using Increment = MeshDimensionsTag< Dimensions + 1 >;
};
template<>
class MeshDimensionTag< 0 >
{
public:
static const int value = 0;
public:
static const int value = 0;
using Increment = MeshDimensionsTag< 1 >;
};
} // namespace Meshes
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment