mirror of
https://gitlab.com/libeigen/eigen.git
synced 2024-12-15 07:10:37 +08:00
Fixed a few compilation warnings
This commit is contained in:
parent
7d41e97fa9
commit
a4aa7c6217
@ -380,7 +380,7 @@ class Tensor : public TensorBase<Tensor<Scalar_, NumIndices_, Options_, IndexTyp
|
||||
EIGEN_DEVICE_FUNC
|
||||
void resize(const Sizes<Indices...>& dimensions) {
|
||||
array<Index, NumIndices> dims;
|
||||
for (int i = 0; i < NumIndices; ++i) {
|
||||
for (std::size_t i = 0; i < NumIndices; ++i) {
|
||||
dims[i] = dimensions[i];
|
||||
}
|
||||
resize(dims);
|
||||
@ -390,7 +390,7 @@ class Tensor : public TensorBase<Tensor<Scalar_, NumIndices_, Options_, IndexTyp
|
||||
EIGEN_DEVICE_FUNC
|
||||
void resize(const Sizes<V1, V2, V3, V4, V5>& dimensions) {
|
||||
array<Index, NumIndices> dims;
|
||||
for (int i = 0; i < NumIndices; ++i) {
|
||||
for (std::size_t i = 0; i < NumIndices; ++i) {
|
||||
dims[i] = dimensions[i];
|
||||
}
|
||||
resize(dims);
|
||||
|
@ -38,7 +38,7 @@ template<typename Index, std::size_t Rank> struct array_size<const DimensionList
|
||||
template<DenseIndex n, typename Index, std::size_t Rank> const Index array_get(DimensionList<Index, Rank>&) {
|
||||
return n;
|
||||
}
|
||||
template<DenseIndex n, typename Index, std::size_t Rank> const Index array_get(const DimensionList<Index, Rank>&a) {
|
||||
template<DenseIndex n, typename Index, std::size_t Rank> const Index array_get(const DimensionList<Index, Rank>&) {
|
||||
return n;
|
||||
}
|
||||
|
||||
|
@ -354,7 +354,3 @@ void test_cxx11_meta()
|
||||
CALL_SUBTEST(test_array_zip_and_apply());
|
||||
CALL_SUBTEST(test_array_misc());
|
||||
}
|
||||
|
||||
/*
|
||||
* kate: space-indent on; indent-width 2; mixedindent off; indent-mode cstyle;
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user