Fix the remaining warnings on my platform

That was mostly "unused locally defined typedefs".
This commit is contained in:
Laurent Rineau 2014-03-27 17:32:06 +01:00
parent ef85ef29fd
commit a8ff620f3f
7 changed files with 43 additions and 12 deletions

View File

@ -93,8 +93,8 @@ void test_algebraic_curve_kernel_2() {
typedef typename AK_2::Algebraic_real_2 Algebraic_real_2;
typedef typename AK_2::Coordinate_1 Coordinate_1;
typedef typename AK_2::Coordinate_2 Coordinate_2;
CGAL_USE_TYPE(Coordinate_1);
typedef typename AK_2::Coordinate_2 Coordinate_2;
CGAL_USE_TYPE(Coordinate_2);
Poly_2 polys[ACK_2_n_polys];

View File

@ -65,8 +65,11 @@ struct ForwardCirculator
BOOST_CONCEPT_USAGE(ForwardCirculator)
{
BOOST_CONCEPT_ASSERT((boost::SignedInteger<difference_type>));
BOOST_CONCEPT_ASSERT((boost::Convertible<iterator_category, CGAL::Forward_circulator_tag>));
// CGAL_UNUSED is needed with g++ 4.8, otherwise it warns:
// "typedef boost_concept_check68 locally defined but not used
// [-Wunused-local-typedefs]"
BOOST_CONCEPT_ASSERT((boost::SignedInteger<difference_type>)) CGAL_UNUSED;
BOOST_CONCEPT_ASSERT((boost::Convertible<iterator_category, CGAL::Forward_circulator_tag>)) CGAL_UNUSED;
boost::require_boolean_expr(a == NULL);
boost::require_boolean_expr(a != NULL);
@ -87,7 +90,7 @@ struct BidirectionalCirculator
{
BOOST_CONCEPT_USAGE(BidirectionalCirculator)
{
BOOST_CONCEPT_ASSERT((boost::Convertible<typename C::iterator_category, CGAL::Bidirectional_circulator_tag>));
BOOST_CONCEPT_ASSERT((boost::Convertible<typename C::iterator_category, CGAL::Bidirectional_circulator_tag>)) CGAL_UNUSED;
--a;
a--;
}
@ -101,7 +104,7 @@ struct RandomAccessCirculator
{
BOOST_CONCEPT_USAGE(RandomAccessCirculator)
{
BOOST_CONCEPT_ASSERT((boost::Convertible<typename C::iterator_category, CGAL::Random_access_circulator_tag>));
BOOST_CONCEPT_ASSERT((boost::Convertible<typename C::iterator_category, CGAL::Random_access_circulator_tag>)) CGAL_UNUSED;
c += n; // addition
c = c + n; c = n + c;
c -= n; // subtraction

View File

@ -12,16 +12,16 @@ int main()
typedef CGAL::Circulator_from_container< std::vector<int> > Circulator_from_vec;
typedef CGAL::Circulator_from_container< std::list<int> > Circulator_from_list;
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_vec>));
BOOST_CONCEPT_ASSERT((CGAL::Concepts::BidirectionalCirculator<Circulator_from_list>));
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_vec>)) CGAL_UNUSED;
BOOST_CONCEPT_ASSERT((CGAL::Concepts::BidirectionalCirculator<Circulator_from_list>)) CGAL_UNUSED;
typedef CGAL::Circulator_from_iterator<int*> Circulator_from_intp;
typedef CGAL::Circulator_from_iterator<std::vector<int>::iterator> Circulator_from_veci;
typedef CGAL::Circulator_from_iterator<std::list<int>::iterator> Circulator_from_listi;
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_intp>));
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_veci>));
BOOST_CONCEPT_ASSERT((CGAL::Concepts::BidirectionalCirculator<Circulator_from_listi>));
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_intp>)) CGAL_UNUSED;
BOOST_CONCEPT_ASSERT((CGAL::Concepts::RandomAccessCirculator<Circulator_from_veci>)) CGAL_UNUSED;
BOOST_CONCEPT_ASSERT((CGAL::Concepts::BidirectionalCirculator<Circulator_from_listi>)) CGAL_UNUSED;
return 0;
}

View File

@ -180,6 +180,8 @@ template < class AT, class ACDE_TAG>
void sqrt_ext_pretty_output_test(){
typedef typename AT::Integer Integer;
typedef CGAL::Sqrt_extension<Integer,Integer> EXT1;
typedef CGAL::Sqrt_extension<EXT1,Integer> EXT2;
CGAL_USE_TYPE(EXT2);
// TEST without Parens_as_product_tag
{
std::stringstream ss;
@ -417,6 +419,8 @@ void fraction_traits_test(){
typedef CGAL::Fraction_traits<INT1_EXT> INT_FT1;
typedef CGAL::Fraction_traits<INT2_EXT> INT_FT2;
typedef CGAL::Fraction_traits<INT3_EXT> INT_FT3;
CGAL_USE_TYPE(INT_FT3);
// RAT_FTs decomposable
assert((boost::is_same< typename RAT_FT1::Is_fraction,

View File

@ -177,9 +177,9 @@ void AT_coercion_test_for_cgal_types_rat(){
typedef CGAL::Sqrt_extension<Integer , Integer> Extn_1;
typedef CGAL::Sqrt_extension<Extn_1 , Extn_1 > Extn_2n;
CGAL_USE_TYPE(Extn_2n);
typedef CGAL::Sqrt_extension<Extn_1 , Integer> Extn_2d;
CGAL_USE_TYPE(Extn_2d); CGAL_USE_TYPE(Extn_2n);
CGAL_USE_TYPE(Extn_2d);
typedef CGAL::Sqrt_extension<Rational , Integer> Extn_rat_int;
CGAL::test_explicit_interoperable_from_to<int ,Extn_rat_int>();

View File

@ -62,35 +62,53 @@ _test_cls_periodic_3_triangulation_3(const PeriodicTriangulation &,
typedef typename P3T3::Offset Offset;
typedef typename P3T3::Iso_cuboid Iso_cuboid;
typedef typename P3T3::Covering_sheets Covering_sheets;
CGAL_USE_TYPE(Covering_sheets);
typedef typename P3T3::Point Point;
typedef typename P3T3::Segment Segment;
typedef typename P3T3::Triangle Triangle;
typedef typename P3T3::Tetrahedron Tetrahedron;
CGAL_USE_TYPE(Segment);
CGAL_USE_TYPE(Triangle);
CGAL_USE_TYPE(Tetrahedron);
typedef typename P3T3::Periodic_point Periodic_point;
typedef typename P3T3::Periodic_segment Periodic_segment;
typedef typename P3T3::Periodic_triangle Periodic_triangle;
typedef typename P3T3::Periodic_tetrahedron Periodic_tetrahedron;
CGAL_USE_TYPE(Periodic_point);
CGAL_USE_TYPE(Periodic_segment);
CGAL_USE_TYPE(Periodic_triangle);
CGAL_USE_TYPE(Periodic_tetrahedron);
typedef typename P3T3::Vertex Vertex;
typedef typename P3T3::Cell Cell;
typedef typename P3T3::Edge Edge;
typedef typename P3T3::Facet Facet;
CGAL_USE_TYPE(Vertex);
CGAL_USE_TYPE(Cell);
typedef typename P3T3::Vertex_handle Vertex_handle;
typedef typename P3T3::Cell_handle Cell_handle;
typedef typename P3T3::size_type size_type;
typedef typename P3T3::difference_type difference_type;
CGAL_USE_TYPE(size_type);
CGAL_USE_TYPE(difference_type);
typedef typename P3T3::Cell_iterator Cell_iterator;
typedef typename P3T3::Facet_iterator Facet_iterator;
typedef typename P3T3::Edge_iterator Edge_iterator;
typedef typename P3T3::Vertex_iterator Vertex_iterator;
CGAL_USE_TYPE(Cell_iterator);
CGAL_USE_TYPE(Facet_iterator);
CGAL_USE_TYPE(Edge_iterator);
CGAL_USE_TYPE(Vertex_iterator);
typedef typename P3T3::Cell_circulator Cell_circulator;
typedef typename P3T3::Facet_circulator Facet_circulator;
CGAL_USE_TYPE(Cell_circulator);
CGAL_USE_TYPE(Facet_circulator);
typedef typename P3T3::Periodic_tetrahedron_iterator
Periodic_tetrahedron_iterator;
@ -99,9 +117,14 @@ _test_cls_periodic_3_triangulation_3(const PeriodicTriangulation &,
typedef typename P3T3::Periodic_segment_iterator
Periodic_segment_iterator;
typedef typename P3T3::Periodic_point_iterator Periodic_point_iterator;
CGAL_USE_TYPE(Periodic_tetrahedron_iterator);
CGAL_USE_TYPE(Periodic_triangle_iterator);
CGAL_USE_TYPE(Periodic_segment_iterator);
CGAL_USE_TYPE(Periodic_point_iterator);
typedef typename P3T3::Locate_type Locate_type;
typedef typename P3T3::Iterator_type Iterator_type;
CGAL_USE_TYPE(Iterator_type);
std::cout<<"Creating triangulations to test on"<<std::endl;
std::cout<<" non-degenerate, 3-sheeted covering"<<std::endl;

View File

@ -31,6 +31,7 @@ void _test_for_given_domain(const Traits & traits,
{
typedef typename Traits::Point_3 Point;
typedef typename Traits::Vector_3 Vector;
CGAL_USE_TYPE(Vector);
typedef typename Traits::Periodic_3_offset_3 Offset;
CGAL_USE_TYPE(typename Traits::Iso_cuboid_3);
typedef typename Traits::Segment_3 Segment;