Skip to content

Commit b7208aa

Browse files
committed
Fix compiler warnings
1 parent c4f0cab commit b7208aa

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

examples/matrix_example.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ void kdtree_demo(const size_t nSamples, const size_t dim)
115115
<< " out_dist_sqr=" << out_dists_sqr[i] << std::endl;
116116
}
117117

118-
int main(int argc, char** argv)
118+
int main(int /*argc*/, char** /*argv*/)
119119
{
120120
// Randomize Seed
121121
// srand(static_cast<unsigned int>(time(nullptr)));

examples/utils.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ struct PointCloud_Orient
182182
// "if/else's" are actually solved at compile time.
183183
inline T kdtree_get_pt(const size_t idx, const size_t dim = 0) const
184184
{
185+
(void)dim;
185186
return pts[idx].theta;
186187
}
187188

include/nanoflann.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1808,7 +1808,8 @@ class KDTreeSingleIndexAdaptor
18081808
// Create a permutable array of indices to the input vectors.
18091809
Base::size_ = dataset_.kdtree_get_point_count();
18101810
if (Base::vAcc_.size() != Base::size_) Base::vAcc_.resize(Base::size_);
1811-
for (Size i = 0; i < Base::size_; i++) Base::vAcc_[i] = i;
1811+
for (IndexType i = 0; i < static_cast<IndexType>(Base::size_); i++)
1812+
Base::vAcc_[i] = i;
18121813
}
18131814

18141815
void computeBoundingBox(BoundingBox& bbox)

0 commit comments

Comments
 (0)