From b0d45fd88fce2dd0e43a1ab3d6f77b069162aae4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jakub=20Klinkovsk=C3=BD?= <klinkjak@fjfi.cvut.cz>
Date: Tue, 31 Oct 2017 23:43:10 +0100
Subject: [PATCH] Removed obsolete todo notes

---
 src/TNL/Meshes/MeshDetails/MeshEntity_impl.h    | 17 ++++-------------
 src/TNL/Meshes/MeshDetails/Mesh_impl.h          |  1 -
 .../layers/MeshSubentityStorageLayer.h          |  2 --
 .../layers/MeshSuperentityStorageLayer.h        |  2 --
 4 files changed, 4 insertions(+), 18 deletions(-)

diff --git a/src/TNL/Meshes/MeshDetails/MeshEntity_impl.h b/src/TNL/Meshes/MeshDetails/MeshEntity_impl.h
index cee5fbdd0d..0139212d2c 100644
--- a/src/TNL/Meshes/MeshDetails/MeshEntity_impl.h
+++ b/src/TNL/Meshes/MeshDetails/MeshEntity_impl.h
@@ -39,7 +39,6 @@ template< typename MeshConfig,
 MeshEntity< MeshConfig, Device, EntityTopology >::
 MeshEntity( const MeshEntity< MeshConfig, Device_, EntityTopology >& entity )
    // no cross-device copy of subentities and superentities here - Mesh constructor has to rebind pointers
-   // TODO: check this
    : MeshEntityIndex< typename MeshConfig::IdType >( entity )
 {
    static_assert( ! std::is_same< Device, Device_ >::value, "this should never happen" );
@@ -70,10 +69,7 @@ operator=( const MeshEntity< MeshConfig, Device_, EntityTopology >& entity )
 {
    static_assert( ! std::is_same< Device, Device_ >::value, "this should never happen" );
 
-   // no cross-device copy here - Mesh::operator= has to rebind pointers
-   // TODO: check this
-//   MeshSubentityAccess< MeshConfig, Device, EntityTopology >::operator=( entity );
-//   MeshSuperentityAccess< MeshConfig, Device, EntityTopology >::operator=( entity );
+   // no cross-device copy of subentities and superentities here - Mesh::operator= has to rebind pointers
    MeshEntityIndex< typename MeshConfig::IdType >::operator=( entity );
    return *this;
 }
@@ -211,7 +207,6 @@ template< typename MeshConfig, typename Device >
 MeshEntity< MeshConfig, Device, MeshVertexTopology >::
 MeshEntity( const MeshEntity< MeshConfig, Device_, MeshVertexTopology >& entity )
    // no cross-device copy of superentities here - Mesh constructor has to rebind pointers
-   // TODO: check this
    : MeshEntityIndex< typename MeshConfig::IdType >( entity )
 {
    static_assert( ! std::is_same< Device, Device_ >::value, "this should never happen" );
@@ -240,9 +235,7 @@ operator=( const MeshEntity< MeshConfig, Device_, MeshVertexTopology >& entity )
 {
    static_assert( ! std::is_same< Device, Device_ >::value, "this should never happen" );
 
-   // no cross-device copy of subentities and superentities here - Mesh::operator= has to rebind pointers
-   // TODO: check this
-//   MeshSuperentityAccess< MeshConfig, Device, EntityTopology >::operator=( entity );
+   // no cross-device copy of superentities here - Mesh::operator= has to rebind pointers
    MeshEntityIndex< typename MeshConfig::IdType >::operator=( entity );
    setPoint( entity.getPoint() );
    return *this;
@@ -269,8 +262,7 @@ bool
 MeshEntity< MeshConfig, Device, MeshVertexTopology >::
 save( File& file ) const
 {
-   if( //! MeshSuperentityStorageLayers< MeshConfig, Device, MeshVertexTopology >::save( file ) ||
-       ! point.save( file ) )
+   if( ! point.save( file ) )
       return false;
    return true;
 }
@@ -280,8 +272,7 @@ bool
 MeshEntity< MeshConfig, Device, MeshVertexTopology >::
 load( File& file )
 {
-   if( //! MeshSuperentityStorageLayers< MeshConfig, Device, MeshVertexTopology >::load( file ) ||
-       ! point.load( file ) )
+   if( ! point.load( file ) )
       return false;
    return true;
 }
diff --git a/src/TNL/Meshes/MeshDetails/Mesh_impl.h b/src/TNL/Meshes/MeshDetails/Mesh_impl.h
index 5e0e9cfbfd..0ad21e359b 100644
--- a/src/TNL/Meshes/MeshDetails/Mesh_impl.h
+++ b/src/TNL/Meshes/MeshDetails/Mesh_impl.h
@@ -257,7 +257,6 @@ load( File& file )
       std::cerr << "Mesh loading failed." << std::endl;
       return false;
    }
-   // TODO: this could be done from the storage layer
    // update pointers from entities into the subentity and superentity storage networks
    MeshEntityStorageRebinder< Mesh< MeshConfig, Device > >::exec( *this );
    return true;
diff --git a/src/TNL/Meshes/MeshDetails/layers/MeshSubentityStorageLayer.h b/src/TNL/Meshes/MeshDetails/layers/MeshSubentityStorageLayer.h
index 28557bd2d8..ebd67aa96c 100644
--- a/src/TNL/Meshes/MeshDetails/layers/MeshSubentityStorageLayer.h
+++ b/src/TNL/Meshes/MeshDetails/layers/MeshSubentityStorageLayer.h
@@ -95,7 +95,6 @@ protected:
    MeshSubentityStorageLayer& operator=( const MeshSubentityStorageLayer& other )
    {
       BaseType::operator=( other );
-      // TODO: throw exception if allocation fails
       storageNetwork.setLike( other.storageNetwork );
       storageNetwork = other.storageNetwork;
       return *this;
@@ -105,7 +104,6 @@ protected:
    MeshSubentityStorageLayer& operator=( const MeshSubentityStorageLayer< MeshConfig, Device_, EntityTopology, SubdimensionTag >& other )
    {
       BaseType::operator=( other );
-      // TODO: throw exception if allocation fails
       storageNetwork.setLike( other.storageNetwork );
       storageNetwork = other.storageNetwork;
       return *this;
diff --git a/src/TNL/Meshes/MeshDetails/layers/MeshSuperentityStorageLayer.h b/src/TNL/Meshes/MeshDetails/layers/MeshSuperentityStorageLayer.h
index 5ba307fb87..9fe663a32f 100644
--- a/src/TNL/Meshes/MeshDetails/layers/MeshSuperentityStorageLayer.h
+++ b/src/TNL/Meshes/MeshDetails/layers/MeshSuperentityStorageLayer.h
@@ -96,7 +96,6 @@ protected:
    MeshSuperentityStorageLayer& operator=( const MeshSuperentityStorageLayer& other )
    {
       BaseType::operator=( other );
-      // TODO: throw exception if allocation fails
       storageNetwork.setLike( other.storageNetwork );
       storageNetwork = other.storageNetwork;
       return *this;
@@ -106,7 +105,6 @@ protected:
    MeshSuperentityStorageLayer& operator=( const MeshSuperentityStorageLayer< MeshConfig, Device_, EntityTopology, SuperdimensionTag >& other )
    {
       BaseType::operator=( other );
-      // TODO: throw exception if allocation fails
       storageNetwork.setLike( other.storageNetwork );
       storageNetwork = other.storageNetwork;
       return *this;
-- 
GitLab