mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
fix compilation error thanks to test case by Trevor Irons, and expand unit test
This commit is contained in:
@@ -22,8 +22,8 @@
|
||||
// License and a copy of the GNU General Public License along with
|
||||
// Eigen. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#ifndef EIGEN_COEFFS_H
|
||||
#define EIGEN_COEFFS_H
|
||||
#ifndef EIGEN_DENSECOEFFSBASE_H
|
||||
#define EIGEN_DENSECOEFFSBASE_H
|
||||
|
||||
template<typename Derived, bool EnableDirectAccessAPI>
|
||||
class DenseCoeffsBase : public EigenBase<Derived>
|
||||
@@ -599,4 +599,4 @@ struct ei_outer_stride_at_compile_time<Derived, false>
|
||||
enum { ret = 0 };
|
||||
};
|
||||
|
||||
#endif // EIGEN_COEFFS_H
|
||||
#endif // EIGEN_DENSECOEFFSBASE_H
|
||||
|
||||
@@ -334,7 +334,7 @@ template<typename Scalar>
|
||||
struct ei_scalar_imag_ref_op {
|
||||
EIGEN_EMPTY_STRUCT_CTOR(ei_scalar_imag_ref_op)
|
||||
typedef typename NumTraits<Scalar>::Real result_type;
|
||||
EIGEN_STRONG_INLINE result_type& operator() (Scalar& a) const { return ei_imag_ref(*const_cast<Scalar*>(&a)); }
|
||||
EIGEN_STRONG_INLINE result_type& operator() (const Scalar& a) const { return ei_imag_ref(*const_cast<Scalar*>(&a)); }
|
||||
};
|
||||
template<typename Scalar>
|
||||
struct ei_functor_traits<ei_scalar_imag_ref_op<Scalar> >
|
||||
|
||||
Reference in New Issue
Block a user