boost::int -> std::int

This commit is contained in:
Sébastien Loriot 2023-04-23 18:43:10 +02:00
parent fc034c6a5d
commit 99e7f4806a
20 changed files with 107 additions and 107 deletions

View File

@ -39,7 +39,7 @@
typedef char CGAL_INT8;
typedef short CGAL_INT16;
typedef boost::int32_t CGAL_INT32;
typedef std::int32_t CGAL_INT32;
typedef unsigned char CGAL_UINT8;
typedef unsigned short CGAL_UINT16;
typedef std::uint32_t CGAL_UINT32;

View File

@ -61,7 +61,7 @@ struct VTK_type_generator<std::uint8_t> {
};
template <>
struct VTK_type_generator<boost::int16_t> {
struct VTK_type_generator<std::int16_t> {
static const int type = VTK_SHORT;
typedef vtkShortArray ArrayType;
};
@ -73,7 +73,7 @@ struct VTK_type_generator<std::uint16_t> {
};
template <>
struct VTK_type_generator<boost::int32_t> {
struct VTK_type_generator<std::int32_t> {
static const int type = VTK_INT;
typedef vtkIntArray ArrayType;
};

View File

@ -23,7 +23,7 @@ namespace CGAL {
class Hyperbolic_data
{
typedef boost::int8_t Id;
typedef std::int8_t Id;
private:
// - 2 for infinite face

View File

@ -34,9 +34,9 @@
namespace CGAL {
typedef boost::int8_t Integer8;
typedef boost::int16_t Integer16;
typedef boost::int32_t Integer32;
typedef std::int8_t Integer8;
typedef std::int16_t Integer16;
typedef std::int32_t Integer32;
typedef std::uint8_t UInteger8;
typedef std::uint16_t UInteger16;
@ -45,7 +45,7 @@ namespace CGAL {
#ifndef BOOST_NO_INT64_T
// this macro is still provided but its use is discouraged
# define CGAL_HAS_INTEGER64
typedef boost::int64_t Integer64;
typedef std::int64_t Integer64;
typedef std::uint64_t UInteger64;
#endif

View File

@ -7,11 +7,11 @@ int main()
std::cout << "Verifying the sizes of boost::[u]int{8,16,32,64}_t"
<< std::endl;
CGAL_static_assertion(sizeof(boost::int8_t) == 1);
CGAL_static_assertion(sizeof(boost::int16_t) == 2);
CGAL_static_assertion(sizeof(boost::int32_t) == 4);
CGAL_static_assertion(sizeof(std::int8_t) == 1);
CGAL_static_assertion(sizeof(std::int16_t) == 2);
CGAL_static_assertion(sizeof(std::int32_t) == 4);
#ifndef BOOST_NO_INT64_T
CGAL_static_assertion(sizeof(boost::int64_t) == 8);
CGAL_static_assertion(sizeof(std::int64_t) == 8);
#endif
CGAL_static_assertion(sizeof(std::uint8_t) == 1);

View File

@ -32,9 +32,9 @@ int main (int argc, char** argv)
std::cerr << " * " << properties[i] << std::endl;
// Recover "label" property of type int
Point_set::Property_map<boost::int32_t> label_prop;
Point_set::Property_map<std::int32_t> label_prop;
bool found = false;
boost::tie(label_prop, found) = point_set.property_map<boost::int32_t> ("label");
boost::tie(label_prop, found) = point_set.property_map<std::int32_t> ("label");
if(found)
{

View File

@ -118,10 +118,10 @@ public:
continue;
}
if(dynamic_cast<PLY_read_typed_number<boost::int8_t>*>(property))
if(dynamic_cast<PLY_read_typed_number<std::int8_t>*>(property))
{
m_properties.push_back
(new PLY_property_to_point_set_property<boost::int8_t>(m_point_set,
(new PLY_property_to_point_set_property<std::int8_t>(m_point_set,
name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint8_t>*>(property))
@ -130,10 +130,10 @@ public:
(new PLY_property_to_point_set_property<std::uint8_t>(m_point_set,
name));
}
else if(dynamic_cast<PLY_read_typed_number<boost::int16_t>*>(property))
else if(dynamic_cast<PLY_read_typed_number<std::int16_t>*>(property))
{
m_properties.push_back
(new PLY_property_to_point_set_property<boost::int16_t>(m_point_set,
(new PLY_property_to_point_set_property<std::int16_t>(m_point_set,
name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint16_t>*>(property))
@ -142,10 +142,10 @@ public:
(new PLY_property_to_point_set_property<std::uint16_t>(m_point_set,
name));
}
else if(dynamic_cast<PLY_read_typed_number<boost::int32_t>*>(property))
else if(dynamic_cast<PLY_read_typed_number<std::int32_t>*>(property))
{
m_properties.push_back
(new PLY_property_to_point_set_property<boost::int32_t>(m_point_set,
(new PLY_property_to_point_set_property<std::int32_t>(m_point_set,
name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint32_t>*>(property))
@ -456,13 +456,13 @@ bool write_PLY(std::ostream& os,
typedef typename Point_set::Index Index;
typedef typename Point_set::Point_map Point_map;
typedef typename Point_set::Vector_map Vector_map;
typedef typename Point_set::template Property_map<boost::int8_t> Int8_map;
typedef typename Point_set::template Property_map<std::int8_t> Int8_map;
typedef typename Point_set::template Property_map<std::uint8_t> Uint8_map;
typedef typename Point_set::template Property_map<boost::int16_t> Int16_map;
typedef typename Point_set::template Property_map<std::int16_t> Int16_map;
typedef typename Point_set::template Property_map<std::uint16_t> Uint16_map;
typedef typename Point_set::template Property_map<boost::int32_t> Int32_map;
typedef typename Point_set::template Property_map<std::int32_t> Int32_map;
typedef typename Point_set::template Property_map<std::uint32_t> Uint32_map;
typedef typename Point_set::template Property_map<boost::int64_t> Int64_map;
typedef typename Point_set::template Property_map<std::int64_t> Int64_map;
typedef typename Point_set::template Property_map<std::uint64_t> Uint64_map;
typedef typename Point_set::template Property_map<float> Float_map;
typedef typename Point_set::template Property_map<double> Double_map;
@ -541,7 +541,7 @@ bool write_PLY(std::ostream& os,
bool okay = false;
{
Int8_map pmap;
boost::tie(pmap, okay) = point_set.template property_map<boost::int8_t>(prop[i]);
boost::tie(pmap, okay) = point_set.template property_map<std::int8_t>(prop[i]);
if(okay)
{
os << "property char " << prop[i] << std::endl;
@ -561,7 +561,7 @@ bool write_PLY(std::ostream& os,
}
{
Int16_map pmap;
boost::tie(pmap, okay) = point_set.template property_map<boost::int16_t>(prop[i]);
boost::tie(pmap, okay) = point_set.template property_map<std::int16_t>(prop[i]);
if(okay)
{
os << "property short " << prop[i] << std::endl;
@ -581,7 +581,7 @@ bool write_PLY(std::ostream& os,
}
{
Int32_map pmap;
boost::tie(pmap, okay) = point_set.template property_map<boost::int32_t>(prop[i]);
boost::tie(pmap, okay) = point_set.template property_map<std::int32_t>(prop[i]);
if(okay)
{
os << "property int " << prop[i] << std::endl;
@ -601,11 +601,11 @@ bool write_PLY(std::ostream& os,
}
{
Int64_map pmap;
boost::tie(pmap, okay) = point_set.template property_map<boost::int64_t>(prop[i]);
boost::tie(pmap, okay) = point_set.template property_map<std::int64_t>(prop[i]);
if(okay)
{
os << "property int " << prop[i] << std::endl;
printers.push_back(new internal::Simple_property_printer<Index,Int64_map,boost::int32_t>(pmap));
printers.push_back(new internal::Simple_property_printer<Index,Int64_map,std::int32_t>(pmap));
continue;
}
}

View File

@ -773,15 +773,15 @@ void Cluster_classification::add_remaining_point_set_properties_as_features(Feat
prop[i] == "r" || prop[i] == "g" || prop[i] == "b")
continue;
if (try_adding_simple_feature<boost::int8_t>(feature_set, prop[i]))
if (try_adding_simple_feature<std::int8_t>(feature_set, prop[i]))
continue;
if (try_adding_simple_feature<std::uint8_t>(feature_set, prop[i]))
continue;
if (try_adding_simple_feature<boost::int16_t>(feature_set, prop[i]))
if (try_adding_simple_feature<std::int16_t>(feature_set, prop[i]))
continue;
if (try_adding_simple_feature<std::uint16_t>(feature_set, prop[i]))
continue;
if (try_adding_simple_feature<boost::int32_t>(feature_set, prop[i]))
if (try_adding_simple_feature<std::int32_t>(feature_set, prop[i]))
continue;
if (try_adding_simple_feature<std::uint32_t>(feature_set, prop[i]))
continue;

View File

@ -668,15 +668,15 @@ void Point_set_item_classification::add_remaining_point_set_properties_as_featur
prop[i] == "r" || prop[i] == "g" || prop[i] == "b")
continue;
if (try_adding_simple_feature<boost::int8_t>(prop[i]))
if (try_adding_simple_feature<std::int8_t>(prop[i]))
continue;
if (try_adding_simple_feature<std::uint8_t>(prop[i]))
continue;
if (try_adding_simple_feature<boost::int16_t>(prop[i]))
if (try_adding_simple_feature<std::int16_t>(prop[i]))
continue;
if (try_adding_simple_feature<std::uint16_t>(prop[i]))
continue;
if (try_adding_simple_feature<boost::int32_t>(prop[i]))
if (try_adding_simple_feature<std::int32_t>(prop[i]))
continue;
if (try_adding_simple_feature<std::uint32_t>(prop[i]))
continue;

View File

@ -1754,7 +1754,7 @@ private:
return false;
}
if(ps->template property_map<boost::int8_t>(name).second)
if(ps->template property_map<std::int8_t>(name).second)
{
return true;
}
@ -1762,7 +1762,7 @@ private:
{
return true;
}
if(ps->template property_map<boost::int16_t>(name).second)
if(ps->template property_map<std::int16_t>(name).second)
{
return true;
}
@ -1770,7 +1770,7 @@ private:
{
return true;
}
if(ps->template property_map<boost::int32_t>(name).second)
if(ps->template property_map<std::int32_t>(name).second)
{
return true;
}
@ -1778,7 +1778,7 @@ private:
{
return true;
}
if(ps->template property_map<boost::int64_t>(name).second)
if(ps->template property_map<std::int64_t>(name).second)
{
return true;
}
@ -1801,7 +1801,7 @@ private:
bool DisplayPropertyPlugin::is_property_scalar(std::string name, const SMesh* sm)
{
if(sm->template property_map<Simplex,boost::int8_t>(name).second)
if(sm->template property_map<Simplex,std::int8_t>(name).second)
{
return true;
}
@ -1809,7 +1809,7 @@ private:
{
return true;
}
if(sm->template property_map<Simplex,boost::int16_t>(name).second)
if(sm->template property_map<Simplex,std::int16_t>(name).second)
{
return true;
}
@ -1817,7 +1817,7 @@ private:
{
return true;
}
if(sm->template property_map<Simplex,boost::int32_t>(name).second)
if(sm->template property_map<Simplex,std::int32_t>(name).second)
{
return true;
}
@ -1825,7 +1825,7 @@ private:
{
return true;
}
if(sm->template property_map<Simplex,boost::int64_t>(name).second)
if(sm->template property_map<Simplex,std::int64_t>(name).second)
{
return true;
}
@ -1846,13 +1846,13 @@ private:
bool DisplayPropertyPlugin::treat_point_property(std::string name, Point_set* ps)
{
typedef typename Point_set::template Property_map<boost::int8_t> Int8_map;
typedef typename Point_set::template Property_map<std::int8_t> Int8_map;
typedef typename Point_set::template Property_map<std::uint8_t> Uint8_map;
typedef typename Point_set::template Property_map<boost::int16_t> Int16_map;
typedef typename Point_set::template Property_map<std::int16_t> Int16_map;
typedef typename Point_set::template Property_map<std::uint16_t> Uint16_map;
typedef typename Point_set::template Property_map<boost::int32_t> Int32_map;
typedef typename Point_set::template Property_map<std::int32_t> Int32_map;
typedef typename Point_set::template Property_map<std::uint32_t> Uint32_map;
typedef typename Point_set::template Property_map<boost::int64_t> Int64_map;
typedef typename Point_set::template Property_map<std::int64_t> Int64_map;
typedef typename Point_set::template Property_map<std::uint64_t> Uint64_map;
typedef typename Point_set::template Property_map<float> Float_map;
typedef typename Point_set::template Property_map<double> Double_map;
@ -1860,7 +1860,7 @@ private:
bool okay = false;
{
Int8_map pmap;
std::tie(pmap, okay) = ps->property_map<boost::int8_t>(name);
std::tie(pmap, okay) = ps->property_map<std::int8_t>(name);
if(okay)
{
return displayPSProperty(ps, pmap);
@ -1878,7 +1878,7 @@ private:
{
Int16_map pmap;
std::tie(pmap, okay) = ps->property_map<boost::int16_t>(name);
std::tie(pmap, okay) = ps->property_map<std::int16_t>(name);
if(okay)
{
return displayPSProperty(ps, pmap);
@ -1896,7 +1896,7 @@ private:
{
Int32_map pmap;
std::tie(pmap, okay) = ps->property_map<boost::int32_t>(name);
std::tie(pmap, okay) = ps->property_map<std::int32_t>(name);
if(okay)
{
return displayPSProperty(ps, pmap);
@ -1914,7 +1914,7 @@ private:
{
Int64_map pmap;
std::tie(pmap, okay) = ps->property_map<boost::int64_t>(name);
std::tie(pmap, okay) = ps->property_map<std::int64_t>(name);
if(okay)
{
return displayPSProperty(ps, pmap);
@ -1953,13 +1953,13 @@ private:
template<typename TAG>
bool DisplayPropertyPlugin::treat_sm_property(std::string name, SMesh* sm)
{
typedef typename SMesh::template Property_map<TAG, boost::int8_t> Int8_map;
typedef typename SMesh::template Property_map<TAG, std::int8_t> Int8_map;
typedef typename SMesh::template Property_map<TAG, std::uint8_t> Uint8_map;
typedef typename SMesh::template Property_map<TAG, boost::int16_t> Int16_map;
typedef typename SMesh::template Property_map<TAG, std::int16_t> Int16_map;
typedef typename SMesh::template Property_map<TAG, std::uint16_t> Uint16_map;
typedef typename SMesh::template Property_map<TAG, boost::int32_t> Int32_map;
typedef typename SMesh::template Property_map<TAG, std::int32_t> Int32_map;
typedef typename SMesh::template Property_map<TAG, std::uint32_t> Uint32_map;
typedef typename SMesh::template Property_map<TAG, boost::int64_t> Int64_map;
typedef typename SMesh::template Property_map<TAG, std::int64_t> Int64_map;
typedef typename SMesh::template Property_map<TAG, std::uint64_t> Uint64_map;
typedef typename SMesh::template Property_map<TAG, float> Float_map;
typedef typename SMesh::template Property_map<TAG, double> Double_map;
@ -1967,7 +1967,7 @@ private:
bool okay = false;
{
Int8_map pmap;
std::tie(pmap, okay) = sm->property_map<TAG,boost::int8_t>(name);
std::tie(pmap, okay) = sm->property_map<TAG,std::int8_t>(name);
if(okay)
{
return displaySMProperty(*sm, pmap, TAG());
@ -1985,7 +1985,7 @@ private:
{
Int16_map pmap;
std::tie(pmap, okay) = sm->property_map<TAG,boost::int16_t>(name);
std::tie(pmap, okay) = sm->property_map<TAG,std::int16_t>(name);
if(okay)
{
return displaySMProperty(*sm, pmap, TAG());
@ -2003,7 +2003,7 @@ private:
{
Int32_map pmap;
std::tie(pmap, okay) = sm->property_map<TAG,boost::int32_t>(name);
std::tie(pmap, okay) = sm->property_map<TAG,std::int32_t>(name);
if(okay)
{
return displaySMProperty(*sm, pmap, TAG());
@ -2021,7 +2021,7 @@ private:
{
Int64_map pmap;
std::tie(pmap, okay) = sm->property_map<TAG,boost::int64_t>(name);
std::tie(pmap, okay) = sm->property_map<TAG,std::int64_t>(name);
if(okay)
{
return displaySMProperty(*sm, pmap, TAG());

View File

@ -549,9 +549,9 @@ template <> const char* whatType(float) { return "float"; }
template <> const char* whatType(double) { return "double"; }
template <> const char* whatType(char) { return "int8_t (char)"; }
template <> const char* whatType(std::uint8_t) { return "uint8_t (unsigned char)"; }
template <> const char* whatType(boost::int16_t) { return "int16_t (short)"; }
template <> const char* whatType(std::int16_t) { return "int16_t (short)"; }
template <> const char* whatType(std::uint16_t) { return "uint16_t (unsigned short)"; }
template <> const char* whatType(boost::int32_t) { return "int32_t (int)"; }
template <> const char* whatType(std::int32_t) { return "int32_t (int)"; }
template <> const char* whatType(std::uint32_t) { return "uint32_t (unsigned int)"; }
template<typename Word>

View File

@ -40,7 +40,7 @@ Random()
std::time( &s);
seed = (unsigned int)s;
// initialize random numbers generator
rng.seed(static_cast<boost::int32_t>(seed));
rng.seed(static_cast<std::int32_t>(seed));
random_value = get_int(0, 1<<15);
}
@ -55,7 +55,7 @@ Random(internal::Random_print_seed)
seed = (unsigned int)s;
std::cerr << "CGAL::Random()::get_seed() = " << seed << std::endl;
// initialize random numbers generator
rng.seed(static_cast<boost::int32_t>(seed));
rng.seed(static_cast<std::int32_t>(seed));
random_value = get_int(0, 1<<15);
}
@ -65,7 +65,7 @@ Random( unsigned int seed)
: val(0), seed(seed)
{
// initialize random numbers generator
rng.seed(static_cast<boost::int32_t>(seed));
rng.seed(static_cast<std::int32_t>(seed));
random_value = get_int(0, 1<<15);
}

View File

@ -435,7 +435,7 @@ namespace CGAL {
private:
// private variables for leaf nodes
boost::int32_t n; // denotes number of items in a leaf node
std::int32_t n; // denotes number of items in a leaf node
iterator data; // iterator to data in leaf node
@ -503,7 +503,7 @@ namespace CGAL {
private:
// private variables for internal nodes
boost::int32_t cut_dim;
std::int32_t cut_dim;
FT cut_val;
Node_handle lower_ch, upper_ch;

View File

@ -348,7 +348,7 @@ std::istream& operator>>( std::istream& in, File_header_OFF& h) {
// Read remaining size value(s).
int n_h;
if ( h.binary()) {
boost::int32_t a, b, c;
std::int32_t a, b, c;
I_Binary_read_big_endian_integer32( in, a);
if ( h.n_dimensional()) {
h.set_dimension( a);

View File

@ -656,7 +656,7 @@ public:
if(has_colors())
{
boost::int32_t k;
std::int32_t k;
I_Binary_read_big_endian_integer32(m_in, k);
if(k<0 || k>4)
{
@ -688,7 +688,7 @@ public:
CGAL_assertion(current_facet < size_of_facets());
if(binary())
{
boost::int32_t i32;
std::int32_t i32;
I_Binary_read_big_endian_integer32(m_in, i32);
size = i32;
}
@ -735,7 +735,7 @@ public:
std::size_t current_facet)
{
if(binary()){
boost::int32_t i32;
std::int32_t i32;
I_Binary_read_big_endian_integer32(m_in, i32);
index = i32;
}
@ -793,7 +793,7 @@ public:
// Take care of trailing information like color triples.
if(binary())
{
boost::int32_t k;
std::int32_t k;
I_Binary_read_big_endian_integer32(m_in, k);
if(k<0 || k>4)
{

View File

@ -129,7 +129,7 @@ public:
void write_facet_begin(std::size_t no)
{
if(m_header.binary())
I_Binary_write_big_endian_integer32(out(), static_cast<boost::int32_t>(no));
I_Binary_write_big_endian_integer32(out(), static_cast<std::int32_t>(no));
else
out() << no << ' ';
}
@ -137,7 +137,7 @@ public:
void write_facet_vertex_index(std::size_t index)
{
if(m_header.binary())
I_Binary_write_big_endian_integer32(out(), static_cast<boost::int32_t>(index));
I_Binary_write_big_endian_integer32(out(), static_cast<std::int32_t>(index));
else
out() << ' ' << index;
}

View File

@ -131,17 +131,17 @@ bool read_PLY(std::istream& is,
}
else if(element.name() == "face" || element.name() == "faces")
{
if(element.has_property<std::vector<boost::int32_t> >("vertex_indices"))
if(element.has_property<std::vector<std::int32_t> >("vertex_indices"))
{
internal::read_PLY_faces<boost::int32_t>(is, element, polygons, fc_out, "vertex_indices");
internal::read_PLY_faces<std::int32_t>(is, element, polygons, fc_out, "vertex_indices");
}
else if(element.has_property<std::vector<std::uint32_t> >("vertex_indices"))
{
internal::read_PLY_faces<std::uint32_t>(is, element, polygons, fc_out, "vertex_indices");
}
else if(element.has_property<std::vector<boost::int32_t> >("vertex_index"))
else if(element.has_property<std::vector<std::int32_t> >("vertex_index"))
{
internal::read_PLY_faces<boost::int32_t>(is, element, polygons, fc_out, "vertex_index");
internal::read_PLY_faces<std::int32_t>(is, element, polygons, fc_out, "vertex_index");
}
else if(element.has_property<std::vector<std::uint32_t> >("vertex_index"))
{

View File

@ -38,11 +38,11 @@
#define TRY_TO_GENERATE_LIST_PROPERTY(STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE) \
TRY_TO_GENERATE_SIZED_LIST_PROPERTY("uchar", "uint8", std::uint8_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("char", "int8", boost::int8_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("char", "int8", std::int8_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("ushort", "uint16", std::uint16_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("short", "int16", boost::int16_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("short", "int16", std::int16_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("uint", "uint32", std::uint32_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE); \
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("int", "int32", boost::int32_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE)
else TRY_TO_GENERATE_SIZED_LIST_PROPERTY("int", "int32", std::int32_t, STD_INDEX_TYPE, T_INDEX_TYPE, INDEX_TYPE)
namespace CGAL {
@ -529,22 +529,22 @@ public:
return false;
}
TRY_TO_GENERATE_LIST_PROPERTY("char", "int8", boost::int8_t);
TRY_TO_GENERATE_LIST_PROPERTY("char", "int8", std::int8_t);
else TRY_TO_GENERATE_LIST_PROPERTY("uchar", "uint8", std::uint8_t);
else TRY_TO_GENERATE_LIST_PROPERTY("short", "int16", boost::int16_t);
else TRY_TO_GENERATE_LIST_PROPERTY("short", "int16", std::int16_t);
else TRY_TO_GENERATE_LIST_PROPERTY("ushort", "uint16", std::uint16_t);
else TRY_TO_GENERATE_LIST_PROPERTY("int", "int32", boost::int32_t);
else TRY_TO_GENERATE_LIST_PROPERTY("int", "int32", std::int32_t);
else TRY_TO_GENERATE_LIST_PROPERTY("uint", "uint32", std::uint32_t);
else TRY_TO_GENERATE_LIST_PROPERTY("float", "float32", float);
else TRY_TO_GENERATE_LIST_PROPERTY("double", "float64", double);
}
else
{
TRY_TO_GENERATE_PROPERTY("char", "int8", boost::int8_t);
TRY_TO_GENERATE_PROPERTY("char", "int8", std::int8_t);
else TRY_TO_GENERATE_PROPERTY("uchar", "uint8", std::uint8_t);
else TRY_TO_GENERATE_PROPERTY("short", "int16", boost::int16_t);
else TRY_TO_GENERATE_PROPERTY("short", "int16", std::int16_t);
else TRY_TO_GENERATE_PROPERTY("ushort", "uint16", std::uint16_t);
else TRY_TO_GENERATE_PROPERTY("int", "int32", boost::int32_t);
else TRY_TO_GENERATE_PROPERTY("int", "int32", std::int32_t);
else TRY_TO_GENERATE_PROPERTY("uint", "uint32", std::uint32_t);
else TRY_TO_GENERATE_PROPERTY("float", "float32", float);
else TRY_TO_GENERATE_PROPERTY("double", "float64", double);

View File

@ -145,10 +145,10 @@ public:
const std::string& name = property->name();
if(name == "vertex_indices" || name == "vertex_index")
{
CGAL_assertion(dynamic_cast<PLY_read_typed_list<boost::int32_t>*>(property)
CGAL_assertion(dynamic_cast<PLY_read_typed_list<std::int32_t>*>(property)
|| dynamic_cast<PLY_read_typed_list<std::uint32_t>*>(property));
m_index_tag = name;
m_use_int32_t = dynamic_cast<PLY_read_typed_list<boost::int32_t>*>(property);
m_use_int32_t = dynamic_cast<PLY_read_typed_list<std::int32_t>*>(property);
return true;
}
if(name == "red" ||
@ -218,25 +218,25 @@ public:
const std::string& name = property->name();
if(dynamic_cast<PLY_read_typed_number<boost::int8_t>*>(property))
if(dynamic_cast<PLY_read_typed_number<std::int8_t>*>(property))
{
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, boost::int8_t>(m_mesh, name));
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, std::int8_t>(m_mesh, name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint8_t>*>(property))
{
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, std::uint8_t>(m_mesh, name));
}
else if(dynamic_cast<PLY_read_typed_number<boost::int16_t>*>(property))
else if(dynamic_cast<PLY_read_typed_number<std::int16_t>*>(property))
{
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, boost::int16_t>(m_mesh, name));
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, std::int16_t>(m_mesh, name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint16_t>*>(property))
{
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, std::uint16_t>(m_mesh, name));
}
else if(dynamic_cast<PLY_read_typed_number<boost::int32_t>*>(property))
else if(dynamic_cast<PLY_read_typed_number<std::int32_t>*>(property))
{
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, boost::int32_t>(m_mesh, name));
properties.push_back(new PLY_property_to_surface_mesh_property<Simplex, std::int32_t>(m_mesh, name));
}
else if(dynamic_cast<PLY_read_typed_number<std::uint32_t>*>(property))
{
@ -314,7 +314,7 @@ public:
Face_index fi = m_mesh.null_face();
if(m_use_int32_t)
process_line<boost::int32_t>(element, fi);
process_line<std::int32_t>(element, fi);
else
process_line<std::uint32_t>(element, fi);
@ -368,7 +368,7 @@ public:
Edge_index ei = m_mesh.null_edge();
if(m_use_int32_t)
process_line<boost::int32_t>(element, ei);
process_line<std::int32_t>(element, ei);
else
process_line<std::uint32_t>(element, ei);
@ -401,7 +401,7 @@ public:
Halfedge_index hi = m_mesh.null_halfedge();
if(m_use_int32_t)
process_line<boost::int32_t>(element, hi);
process_line<std::int32_t>(element, hi);
else
process_line<std::uint32_t>(element, hi);
@ -640,13 +640,13 @@ void fill_header(std::ostream& os, const Surface_mesh<Point>& sm,
const CGAL_NP_CLASS& np = parameters::default_values())
{
typedef Surface_mesh<Point> SMesh;
typedef typename SMesh::template Property_map<Simplex, boost::int8_t> Int8_map;
typedef typename SMesh::template Property_map<Simplex, std::int8_t> Int8_map;
typedef typename SMesh::template Property_map<Simplex, std::uint8_t> Uint8_map;
typedef typename SMesh::template Property_map<Simplex, boost::int16_t> Int16_map;
typedef typename SMesh::template Property_map<Simplex, std::int16_t> Int16_map;
typedef typename SMesh::template Property_map<Simplex, std::uint16_t> Uint16_map;
typedef typename SMesh::template Property_map<Simplex, boost::int32_t> Int32_map;
typedef typename SMesh::template Property_map<Simplex, std::int32_t> Int32_map;
typedef typename SMesh::template Property_map<Simplex, std::uint32_t> Uint32_map;
typedef typename SMesh::template Property_map<Simplex, boost::int64_t> Int64_map;
typedef typename SMesh::template Property_map<Simplex, std::int64_t> Int64_map;
typedef typename SMesh::template Property_map<Simplex, std::uint64_t> Uint64_map;
typedef typename SMesh::template Property_map<Simplex, float> Float_map;
typedef typename SMesh::template Property_map<Simplex, double> Double_map;
@ -711,7 +711,7 @@ void fill_header(std::ostream& os, const Surface_mesh<Point>& sm,
bool okay = false;
{
Int8_map pmap;
boost::tie(pmap, okay) = sm.template property_map<Simplex,boost::int8_t>(prop[i]);
boost::tie(pmap, okay) = sm.template property_map<Simplex,std::int8_t>(prop[i]);
if(okay)
{
os << "property char " << name << std::endl;
@ -731,7 +731,7 @@ void fill_header(std::ostream& os, const Surface_mesh<Point>& sm,
}
{
Int16_map pmap;
boost::tie(pmap, okay) = sm.template property_map<Simplex,boost::int16_t>(prop[i]);
boost::tie(pmap, okay) = sm.template property_map<Simplex,std::int16_t>(prop[i]);
if(okay)
{
os << "property short " << name << std::endl;
@ -751,7 +751,7 @@ void fill_header(std::ostream& os, const Surface_mesh<Point>& sm,
}
{
Int32_map pmap;
boost::tie(pmap, okay) = sm.template property_map<Simplex,boost::int32_t>(prop[i]);
boost::tie(pmap, okay) = sm.template property_map<Simplex,std::int32_t>(prop[i]);
if(okay)
{
os << "property int " << name << std::endl;
@ -771,11 +771,11 @@ void fill_header(std::ostream& os, const Surface_mesh<Point>& sm,
}
{
Int64_map pmap;
boost::tie(pmap, okay) = sm.template property_map<Simplex,boost::int64_t>(prop[i]);
boost::tie(pmap, okay) = sm.template property_map<Simplex,std::int64_t>(prop[i]);
if(okay)
{
os << "property int " << name << std::endl;
printers.push_back(new internal::Simple_property_printer<Simplex,Int64_map,boost::int32_t>(pmap));
printers.push_back(new internal::Simple_property_printer<Simplex,Int64_map,std::int32_t>(pmap));
continue;
}
}

View File

@ -329,7 +329,7 @@ int main(int argc, char **argv)
}
// Hardcoded seeds so that the test-suite is deterministic.
boost::int32_t seed0 = 42, seed1 = 43, seed2 = 42, seed3 = 42;
std::int32_t seed0 = 42, seed1 = 43, seed2 = 42, seed3 = 42;
// You can also pass seeds on the command line.
if (argc > 1) { std::istringstream iss(argv[1]); iss >>seed0; }