rename is_stack_unbound() -> is_stack_unbounded()

This commit is contained in:
Oliver Kowalke
2014-02-11 18:01:47 +01:00
parent 57c9c0a355
commit f1b55e35c9
8 changed files with 25 additions and 25 deletions

View File

@@ -84,14 +84,14 @@ std::size_t page_count( std::size_t stacksize)
}
bool
protected_stack_allocator::is_stack_unbound()
protected_stack_allocator::is_stack_unbounded()
{ return RLIM_INFINITY == stacksize_limit().rlim_max; }
std::size_t
protected_stack_allocator::default_stacksize()
{
std::size_t size = 8 * minimum_stacksize();
if ( is_stack_unbound() ) return size;
if ( is_stack_unbounded() ) return size;
BOOST_ASSERT( maximum_stacksize() >= minimum_stacksize() );
return maximum_stacksize() == size
@@ -106,7 +106,7 @@ protected_stack_allocator::minimum_stacksize()
std::size_t
protected_stack_allocator::maximum_stacksize()
{
BOOST_ASSERT( ! is_stack_unbound() );
BOOST_ASSERT( ! is_stack_unbounded() );
return static_cast< std::size_t >( stacksize_limit().rlim_max);
}
@@ -114,7 +114,7 @@ void
protected_stack_allocator::allocate( stack_context & ctx, std::size_t size)
{
BOOST_ASSERT( minimum_stacksize() <= size);
BOOST_ASSERT( is_stack_unbound() || ( maximum_stacksize() >= size) );
BOOST_ASSERT( is_stack_unbounded() || ( maximum_stacksize() >= size) );
const std::size_t pages( page_count( size) ); // page at bottom will be used as guard-page
BOOST_ASSERT_MSG( 2 <= pages, "at least two pages must fit into stack (one page is guard-page)");
@@ -153,7 +153,7 @@ protected_stack_allocator::deallocate( stack_context & ctx)
{
BOOST_ASSERT( ctx.sp);
BOOST_ASSERT( minimum_stacksize() <= ctx.size);
BOOST_ASSERT( is_stack_unbound() || ( maximum_stacksize() >= ctx.size) );
BOOST_ASSERT( is_stack_unbounded() || ( maximum_stacksize() >= ctx.size) );
void * limit = static_cast< char * >( ctx.sp) - ctx.size;
// conform to POSIX.4 (POSIX.1b-1993, _POSIX_C_SOURCE=199309L)