mirror of
https://github.com/ETLCPP/etl.git
synced 2026-06-27 21:08:44 +08:00
Modified debug #defines
This commit is contained in:
parent
4b9e9cd651
commit
0906d29278
@ -271,7 +271,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count <= difference_type(capacity()), ETL_ERROR(flat_map_full));
|
||||
#endif
|
||||
|
||||
@ -222,7 +222,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count <= difference_type(capacity()), ETL_ERROR(flat_multimap_full));
|
||||
#endif
|
||||
|
||||
@ -198,7 +198,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count <= difference_type(capacity()), ETL_ERROR(flat_multiset_full));
|
||||
#endif
|
||||
|
||||
@ -198,7 +198,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count <= difference_type(capacity()), ETL_ERROR(flat_set_full));
|
||||
#endif
|
||||
|
||||
@ -354,7 +354,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count >= 0, ETL_ERROR(forward_list_iterator));
|
||||
#endif
|
||||
@ -512,7 +512,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void insert_after(iterator position, TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT((count + current_size) <= MAX_SIZE, ETL_ERROR(forward_list_full));
|
||||
#endif
|
||||
@ -609,7 +609,7 @@ namespace etl
|
||||
return; // Can't more to before yourself!
|
||||
}
|
||||
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
// Check that we are not doing an illegal move!
|
||||
for (const_iterator item = first_before; item != last; ++item)
|
||||
{
|
||||
|
||||
@ -452,7 +452,7 @@ namespace etl
|
||||
template <typename TIterator>
|
||||
void assign(TIterator first, TIterator last)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
difference_type count = std::distance(first, last);
|
||||
ETL_ASSERT(count >= 0, ETL_ERROR(list_iterator));
|
||||
ETL_ASSERT(size_t(count) <= MAX_SIZE, ETL_ERROR(list_full));
|
||||
@ -475,7 +475,7 @@ namespace etl
|
||||
//*************************************************************************
|
||||
void assign(size_t n, parameter_t value)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
ETL_ASSERT(n <= MAX_SIZE, ETL_ERROR(list_full));
|
||||
#endif
|
||||
|
||||
@ -1062,7 +1062,7 @@ namespace etl
|
||||
return; // Can't more to before yourself!
|
||||
}
|
||||
|
||||
#ifdef _DEBUG
|
||||
#if defined(_DEBUG) || defined(DEBUG)
|
||||
// Check that we are not doing an illegal move!
|
||||
for (const_iterator item = first; item != last; ++item)
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user