mirror of
https://github.com/boostorg/geometry.git
synced 2025-05-09 23:24:02 +00:00
[example] Replace assert with BOOST_ASSERT
This commit is contained in:
parent
869cff7004
commit
99b27c611a
@ -12,6 +12,8 @@
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include <boost/assert.hpp>
|
||||
|
||||
#include <boost/iterator.hpp>
|
||||
#include <boost/iterator/iterator_adaptor.hpp>
|
||||
#include <boost/iterator/iterator_categories.hpp>
|
||||
@ -43,14 +45,14 @@ class my_polygon
|
||||
// Const access
|
||||
my_point const& get_point(std::size_t i) const
|
||||
{
|
||||
assert(i < points.size());
|
||||
BOOST_ASSERT(i < points.size());
|
||||
return points[i];
|
||||
}
|
||||
|
||||
// Mutable access
|
||||
my_point & get_point(std::size_t i)
|
||||
{
|
||||
assert(i < points.size());
|
||||
BOOST_ASSERT(i < points.size());
|
||||
return points[i];
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user