Browse Source

Fix operator= is protected in PlainObjectBase

In Eigen 3.3 operator= is a protected member of PlainObjectBase.
This can be fixed by casting the wrapped object reference to its
original type before using operator=.


Former-commit-id: eec8c0ae85a14553063180bac43475bb4c6c419f
Stefan Reinhold 7 years ago
parent
commit
fb6688698b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      include/igl/vertex_triangle_adjacency.cpp

+ 1 - 1
include/igl/vertex_triangle_adjacency.cpp

@@ -70,7 +70,7 @@ IGL_INLINE void igl::vertex_triangle_adjacency(
   // vfd now acts as a counter
   vfd = NI;
 
-  VF = Eigen::VectorXi(3*F.rows());
+  static_cast<DerivedVF &>(VF )= Eigen::VectorXi(3*F.rows());
   for (int i = 0; i < F.rows(); i++)
   {
     for (int j = 0; j < 3; j++)