Ce patch permet � g++ 4.1 de compiler le code enregistr� par Th�o hier
(qui devait compiler avec g++ 3.3). Il y a a probablement d'autres endroits
� modifier de la sorte dans Olena, car le test qui a permis de rep�rer ces
erreurs �tait relativement petit.
Index: ChangeLog
from Ugo Jardonnet <ugo.jardonnet(a)lrde.epita.fr>
Fix name lookup for attribute of super classes.
* olena/oln/core/concept/image.hh,
* olena/oln/core/gen/dpoints_piter.hh,
* olena/oln/core/internal/point_base.hh,
* olena/oln/core/internal/dpoint_base.hh: Fix name lookup
for attribute of super classes.
concept/image.hh | 13 ++++++-------
gen/dpoints_piter.hh | 12 ++++++------
internal/dpoint_base.hh | 2 ++
internal/point_base.hh | 2 ++
4 files changed, 16 insertions(+), 13 deletions(-)
Index: olena/oln/core/concept/image.hh
--- olena/oln/core/concept/image.hh (revision 856)
+++ olena/oln/core/concept/image.hh (working copy)
@@ -412,21 +412,21 @@
typename Fast_Image<Exact>::rvalue
Fast_Image<Exact>::operator[](typename Fast_Image<Exact>::index i) const
{
- return exact(this)->impl_index_read(p);
+ return exact(this)->impl_index_read(i);
}
template <typename Exact>
typename Fast_Image<Exact>::lvalue
Fast_Image<Exact>::operator[](typename Fast_Image<Exact>::index i)
{
- return exact(this)->impl_index_read_write(p);
+ return exact(this)->impl_index_read_write(i);
}
template <typename Exact>
std::size_t
Fast_Image<Exact>::npoints() const
{
- return exact(this)->impl_npoints(p);
+ return exact(this)->impl_npoints();
}
template <typename Exact>
@@ -454,7 +454,6 @@
typename Value_Wise_Mutable_Image<Exact>::lvaluep
Value_Wise_Mutable_Image<Exact>::value(const typename
Value_Wise_Accessible_Image<Exact>::vsite& v)
{
- return exact(this)->impl_value_read_write(p);
}
template <typename Exact>
@@ -503,7 +502,7 @@
bool
Point_Wise_Accessible_Image_2D<Exact>::impl_has_at(coord row, coord col) const
{
- Point_Wise_Accessible_Image_2D<Exact>::point p(row, col);
+ typename Point_Wise_Accessible_Image_2D<Exact>::point p(row, col);
return this->has(p);
}
@@ -511,7 +510,7 @@
typename Point_Wise_Accessible_Image_2D<Exact>::rvalue
Point_Wise_Accessible_Image_2D<Exact>::impl_at(coord row, coord col) const
{
- Point_Wise_Accessible_Image_2D<Exact>::point p(row, col);
+ typename Point_Wise_Accessible_Image_2D<Exact>::point p(row, col);
return this->at(p);
}
@@ -533,7 +532,7 @@
typename Point_Wise_Mutable_Image_2D<Exact>::lvalue
Point_Wise_Mutable_Image_2D<Exact>::impl_at(coord row, coord col)
{
- Point_Wise_Mutable_Image_2D<Exact>::point p(row, col);
+ typename Point_Wise_Mutable_Image_2D<Exact>::point p(row, col);
return this->at(p);
}
Index: olena/oln/core/gen/dpoints_piter.hh
--- olena/oln/core/gen/dpoints_piter.hh (revision 856)
+++ olena/oln/core/gen/dpoints_piter.hh (working copy)
@@ -228,7 +228,7 @@
void
dpoints_fwd_piter_<P>::impl_start()
{
- i_ = 0;
+ this->i_ = 0;
this->update_p_();
}
@@ -236,7 +236,7 @@
void
dpoints_fwd_piter_<P>::impl_next()
{
- if (++i_ == n_)
+ if (++this->i_ == this->n_)
return;
this->update_p_();
}
@@ -256,7 +256,7 @@
void
dpoints_bkd_piter_<P>::impl_start()
{
- i_ = n_ - 1;
+ this->i_ = this->n_ - 1;
this->update_p_();
}
@@ -264,12 +264,12 @@
void
dpoints_bkd_piter_<P>::impl_next()
{
- if (i_ == 0)
+ if (this->i_ == 0)
{
- i_ = n_;
+ this->i_ = this->n_;
return;
}
- --i_;
+ --this->i_;
this->update_p_();
}
Index: olena/oln/core/internal/point_base.hh
--- olena/oln/core/internal/point_base.hh (revision 856)
+++ olena/oln/core/internal/point_base.hh (working copy)
@@ -75,6 +75,8 @@
stc_using(dim);
stc_using(dpoint);
+ using super::n;
+
coord operator[](unsigned i) const;
coord& operator[](unsigned i);
Index: olena/oln/core/internal/dpoint_base.hh
--- olena/oln/core/internal/dpoint_base.hh (revision 856)
+++ olena/oln/core/internal/dpoint_base.hh (working copy)
@@ -76,6 +76,8 @@
stc_using(dim);
stc_using(point);
+ using super::n;
+
coord operator[](unsigned i) const;
coord& operator[](unsigned i);