Commit fcf0c933 authored by incardon's avatar incardon
Browse files

Fixing clang compilation

parent c4c6c3dc
......@@ -80,7 +80,7 @@ public:
distance dist;
// Get the nearest point of the box from the center of the sphere
typename distance::ResultType distance = 0;
typename distance::ResultType distance_r = 0;
for (int i = 0 ; i < dim ; i++)
{
......@@ -91,17 +91,17 @@ public:
if (boost::fusion::at_c<p1>(data)[i] < sphere.center(i))
{
// accumulate the distance from p1
distance += dist.accum_dist(sphere.center(i),boost::fusion::at_c<p1>(data)[i],i);
distance_r += dist.accum_dist(sphere.center(i),boost::fusion::at_c<p1>(data)[i],i);
}
else if ( boost::fusion::at_c<p2>(data)[i] <= sphere.center(i))
{
// accumulate the distance from p2
distance += dist.accum_dist(sphere.center(i),boost::fusion::at_c<p2>(data)[i],i);
distance_r += dist.accum_dist(sphere.center(i),boost::fusion::at_c<p2>(data)[i],i);
}
}
// return if there is intersection
return distance < sphere.radius();
return distance_r < sphere.radius();
}
/*! \brief Get the coordinate of the bounding point
......
......@@ -132,8 +132,8 @@ BOOST_AUTO_TEST_CASE( Hyper_cube_use)
// Check combination
comb<2> c2_0[] = {{1,1},{1,-1},{-1,1},{-1,-1}};
comb<2> c2_1[] = {{1,0},{-1,0},{0,1},{0,-1}};
comb<2> c2_0[] = {{{1,1}},{{1,-1}},{{-1,1}},{{-1,-1}}};
comb<2> c2_1[] = {{{1,0}},{{-1,0}},{{0,1}},{{0,-1}}};
check_lin(v_c2_0);
check_lin(v_c2_1);
......
......@@ -378,7 +378,7 @@ class memory_c<multi_array<T>, D>
//! set the device memory interface, the object that allocate memory
void set_mem(memory & mem)
{
mem = &mem;
this->mem = &mem;
}
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment